52ky 发表于 2022-9-22 16:05:31

GB2312中的汉字编码规则

01-09区为特殊符号。
16-55区为一级汉字,按拼音排序。
56-87区为二级汉字,按部首/笔画排序。
每个汉字及符号以两个字节来表明。第一个字节称为“高位字节”,第二个字节称为“低位字节”。
“高位字节”使用了0xA1-0xF7(把01-87区的区号加上0xA0),“低位字节”使用了0xA1-0xFE(把01-94加上0xA0)。
例如“啊”字在大多数程序中,会以0xB0A1贮存。(与区位码比照:0xB0=0xA0+16,0xA1=0xA0+1)。
GB2312编码表
code+0+1+2+3+4+5+6+7+8+9+A+B+C+D+E+F
A1A0、。·ˉˇ¨〃々—~‖…‘’
A1B0“”〔〕〈〉《》「」『』〖〗【】
A1C0±×÷∶∧∨∑∏∪∩∈∷√⊥∥∠
A1D0⌒⊙∫∮≡≌≈∽∝≠≮≯≤≥∞∵
A1E0∴♂♀°′″℃$¤¢£‰§№**
A1F0○●◎◇◆□■△▲※→←↑↓〓
code+0+1+2+3+4+5+6+7+8+9+A+B+C+D+E+F
A2A0ⅰⅱⅲⅳⅴⅵⅶⅷⅸⅹ
A2B0⒈⒉⒊⒋⒌⒍⒎⒏⒐⒑⒒⒓⒔⒕⒖
A2C0⒗⒘⒙⒚⒛⑴⑵⑶⑷⑸⑹⑺⑻⑼⑽⑾
A2D0⑿⒀⒁⒂⒃⒄⒅⒆⒇①②③④⑤⑥⑦
A2E0⑧⑨⑩€㈠㈡㈢㈣㈤㈥㈦㈧㈨㈩
A2F0ⅠⅡⅢⅣⅤⅥⅦⅧⅨⅩⅪⅫ
code+0+1+2+3+4+5+6+7+8+9+A+B+C+D+E+F
A3A0!#$%'()*+,-./
A3B00123456789:;lt;=gt;?
A3C0@ABCDEFGHIJKLMNO
A3D0PQRSTUVWXYZ[\]^_
A3E0`abcdefghijklmno
A3F0pqrstuvwxyz{}~
GB2312编码表.txt
.....

(Areas 01-09 are special symbols.
Areas 16-55 are first-class Chinese characters, sorted by pinyin.
Areas 56-87 are second-level Chinese characters, sorted by radicals/strokes.
Each Chinese character and symbol is represented by two bytes. The first byte is called "high-order byte", and the second byte is called "low-order byte".
The "high byte" uses 0xA1-0xF7 (add 0xA0 to the area code of the 01-87 area), and the "low byte" uses 0xA1-0xFE (add 01-94 to 0xA0).
For example, the word "ah" will be stored as 0xB0A1 in most programs. (Compare with the area code: 0xB0=0xA0 16, 0xA1=0xA0 1).
GB2312 encoding table
code 0 1 2 3 4 5 6 7 8 9 A B C D E F
A1A0,. ·ˉˇ¨〃々—~‖…‘’
A1B0 ""〔〕<>""""『』〖〗【】
A1C0±×÷: ∧∨∑∏∪∩∈∷√⊥∥∠
A1D0⌒⊙∫∮≡≌≈∽∝≠≮≯≤≥∞∵
A1E0∴♂♀°′″℃$¤¢£‰§№**
A1F0○●◎◇◆□■△▲※→←↑↓〓
code 0 1 2 3 4 5 6 7 8 9 A B C D E F
A2A0ⅰⅱⅲⅳⅴⅵⅶⅷⅸⅹ
A2B0⒈⒉⒊⒋⒌⒍⒎⒏⒐⒑⒒⒓⒔⒕⒖
A2C0⒗⒘⒙⒚⒛⑴⑵⑶⑷⑸⑹⑺⑻⑼⑽⑾
A2D0⑿⒀⒁⒂⒃⒄⒅⒆⒇①②③④⑤⑥⑦
A2E0⑧⑨⑩€㈠㈡㈢㈣㈤㈥㈦㈧㈨㈩
A2F0ⅠⅡⅢⅣⅤⅥⅦⅧⅨⅩⅪⅫ
code 0 1 2 3 4 5 6 7 8 9 A B C D E F
A3A0!#$%'()* ,-./
A3B00123456789:;lt;=gt;?
A3C0@ABCDEFGHIJKLMNO
A3D0PQRSTUVWXYZ[\]^_
A3E0`abcdefghijklmno
A3F0pqrstuvwxyz{}~
GB2312 encoding table.txt
.....)




页: [1]
查看完整版本: GB2312中的汉字编码规则