특수한 변수명

 

1. _string 형태

from module import * 구문에서 import되지 않는다.

interactive한 환경에서는 마지막 expression(표현식)의 결과를 보전하고 있다.

 

2. __string__

시스템에서 정의하는 이름으로 특별한 의미를 갖는다. 사용자는 이러한 형태로 변수명을 만들면 안된다.

 

3. __string

enclosing class에 국한되는 변수들

 

변수명을 짓는 습관

1. 클래스명은 대문자로 시작

2. 모듈명은 소문자로 시작

 

'Python' 카테고리의 다른 글

iteration, iterable, iterator  (0) 2019.12.27
( ) = ( ) if ( ) else ( ) 구문  (0) 2019.12.27
python statements  (0) 2019.12.27
binary data pack unpack examples  (0) 2019.12.27
struct : binary data packing & unpacking options  (0) 2019.12.27

+ Recent posts