使用python打印所有汉字

来源:互联网 发布:js 模块化编程 入门 编辑:程序博客网 时间:2024/04/30 12:24



# -*- coding: utf-8 -*-def print_unicode(start, end):    Start = start    while Start <= end:        ustr = '\u' + hex(Start)[2:]        index = Start - start + 1        print str(index) + '\t' + ustr.decode('unicode-escape')        Start = Start + 1print_unicode(0x4e00, 0x9fbf)


0 0
原创粉丝点击