[Python] dictionary에 default value 사용하기 2020-12-16 Python Python Tricks 책의 7.1 Dictionary Default Values 정리 내용입니다. 아래와 같은 dictionary가 있을때 1 2 3 4 5 arsenal_player_number = { 14: "auba", 10: "ozil", 35: "gabi", } 각 선수이름에 해당하는 등번호를 출력하고 싶다 Read more...
[Python]Decorator 2020-06-06 Python Decorator란? 디자인 패턴 중 하나인 decorator pattern과 비슷한 개념으로, 반복적인 것을 공통화하고, 메소드나 클래스의 기능을 확장할 수 있는 방법이다 Read more...
[Python] coding convention 및 tool 2020-05-10 Python Coding Convention이란? coding convention은 code를 작성하는 구체적인 가이드라인이다. 협업을 위해서는 읽기 쉽고 일관적인 코드를 작성하는 것 Read more...
[Python] Annotation 2020-05-02 Python Annotation이란? annotation은 function의 parameter와 return value에 대한 hint를 주는 것이다. 강제하는 것이 아 Read more...
[Python] Docstring 2020-05-02 Python Docstring이란? docstring은 module, function, class, method에 대한 문서화 작업을 말한다. docstring은 __doc__ special attribute에 저장된다 Read more...