lines = []
for high in xrange(0, 0xff):
highPart = high << 8
line =""
for low in xrange(0, 0xff):
lowPart = low
data = u"%c" % (highPart | lowPart)
try:
data.encode("gb2312")
except UnicodeError:
continue
line += data
if line:
lines.append(line.encode("utf8"))
open("gb2312.txt", "w").write("\n".join(lines))
GB2312 테이블


python 을 좋아하는 게임 프로그래머