Try Chardet(https://pypi.python.org/pypi/chardet)
(Need to change font)
chcp 65001
Want to get back?
chcp 949
Try Chardet(https://pypi.python.org/pypi/chardet)
(Need to change font)
chcp 65001
Want to get back?
chcp 949
| ''' | |
| Python Encoding cheatsheet | |
| Mostly for korean. | |
| All below items are True | |
| ''' | |
| "한글" != u"한글" | |
| "한글" == '\xed\x95\x9c\xea\xb8\x80' | |
| u"한글" == u'\ud55c\uae00' | |
| "한글".decode("utf-8") == u"한글" | |
| "한글" == u"한글".encode("utf-8") | |
| "\ud55c\uae00".decode('unicode_escape') == u"한글" | |
| # #2 > #1 #2 is faster than #1. | |
| "한글".decode("utf-8") in u"asdf한글asdf" #1 | |
| "한글" in u"asdf한글asdf".encode("utf-8") #2 |