numerics_demo.py 文件源码

python
阅读 28 收藏 0 点赞 0 评论 0

项目:Books_SourceCode 作者: activeion 项目源码 文件源码
def print_str(sample):
    for char in sample:
        print('U+%04x' % ord(char),                       # <1>
              char.center(6),                             # <2>
              're_dig' if re_digit.match(char) else '-',  # <3> ?????????
              'isdig' if char.isdigit() else '-',         # <4> ?????
              'isnum' if char.isnumeric() else '-',       # <5> ?????
              format(unicodedata.numeric(char), '5.2f'),  # <6> ????????
              unicodedata.name(char),                     # <7> ????????
              sep='\t')
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号