2017/091 python3 한글 처리. python은 멀티바이트 문자처리가 짜증나게 되어있는듯..가장 많이 쓰이는 python2, python3의 한글 처리 방법이 다름. 먼저 알아두어야할 것.python2, python3의 문자열 처리 방법이 다름.python2은 ascii가 기본python3은 unicode가 기본LINUX와 윈도우의 한글 처리 방법이 다름.윈도우는 CP949가 기본LINUX는 euc-kr이 기본. (.profile에 명기하기 나름이지만, 보통 euc-kr)웹 세상에서는 utf-8이 기본. python3 한글 처리. 123456import sysreload(sys)sys.setdefaultencoding('euc-kr') # 또는 sys.setdefaultencoding('utf-8')a = "한글"print( a )pri.. 2017. 9. 12. 이전 1 다음