강의

멘토링

커뮤니티

Inflearn Community Q&A

scr's profile image
scr

asked

Getting Started with Programming: Introduction to Python (Inflearn Original)

Exception(1-2)

'Exception과' 'Exception as e' 의 차이

Written on

·

264

0

안녕하세요. 

 

위 사진처럼 print(Exception)을 하면 <class 'Exception'>이 출력되고

print(e)를 하면 'Cho' is not in list 라고 뜨는데 차이가 무엇인가요?

그리고 Exception이라는 class가 따로 뜨는데 나중에 배우는 내용인가요?

python

Answer 1

0

niceman님의 프로필 이미지
niceman
Instructor

네 안녕하세요.

엘리아스를 줘서 안에 내용을 출력할 수 있게 해주는 겁니다.

예외 처리 부분에서 배웁니다.

scr's profile image
scr

asked

Ask a question