zoukankan      html  css  js  c++  java
  • 已知GBK的某段码表,码表对应的字符

      for i in range(0xA1A2,0xA1A5):                                                                                                 
            b1=i&0xFF;                                                                                                                 
            b2=i>>8;                                                                                                                   
            GBKChar1=chr(b2);                                                                                                          
            GBKChar2=chr(b1);                                                                                                          
            GBKChar=GBKChar1+GBKChar2;                                                                                                 
            print "%s %0X%0X"%(GBKChar,b2,b1);                                                                                        
        for i in range(0xA1AE,0xA1C0):                                                                                                 
            b1=i&0xFF;                                                                                                                 
            b2=i>>8;                                                                                                                   
            GBKChar1=chr(b2);                                                                                                          
            GBKChar2=chr(b1);                                                                                                          
            GBKChar=GBKChar1+GBKChar2;                                                                                                 
            print "%s %0X%0X"%(GBKChar,b2,b1);                                                                                        
        for i in range(0xA3A1,0xA3B0):                                                                                                 
            b1=i&0xFF;                                                                                                                 
            b2=i>>8;                                                                                                                   
            GBKChar1=chr(b2);                                                                                                          
            GBKChar2=chr(b1);                                                                                                          
            GBKChar=GBKChar1+GBKChar2;                                                                                                 
            print "%s %0X%0X"%(GBKChar,b2,b1);                                                                                        
        for i in range(0xA3BA,0xA3C0):                                                                                                 
            b1=i&0xFF;                                                                                                                 
            b2=i>>8;                                                                                                                   
            GBKChar1=chr(b2);                                                                                                          
            GBKChar2=chr(b1);                                                                                                          
            GBKChar=GBKChar1+GBKChar2;                                                                                                 
            print "%s %0X%0X"%(GBKChar,b2,b1)

  • 相关阅读:
    perl 解json数组
    华为云3大体系化防护实践,保障金融业云上数据安全
    弹性文件服务解密 -- 块存储、文件存储、对象存储的区别
    【nodejs原理&源码赏析(6)】深度剖析cluster模块源码与node.js多进程
    云+AI+5G时代,华为云已准备好多元化云服务架构
    高能街访 | 为什么他们都纷纷为深圳打Call?
    Angularjs进阶笔记(2)—自定义指令中的数据绑定
    Angularjs进阶笔记(1)—不同类型的双向数据绑定
    ServiceComb java-chassis和CSE java-chassis的区别
    使用inspector功能查看和管理契约
  • 原文地址:https://www.cnblogs.com/finallyliuyu/p/5587194.html
Copyright © 2011-2022 走看看