博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
Working with Characters and Strings(Chapter 2 of Windows Via C/C++)
阅读量:5307 次
发布时间:2019-06-14

本文共 936 字,大约阅读时间需要 3 分钟。

  In Windows Vista, each Unicode character is encoded using UTF-16 (where
UTF is an acronym for
Unicode Transformation Format). UTF-16 encodes each character as 2 bytes (or 16 bits).

  UTF-8 UTF-8 encodes some characters as 1 byte, some characters as 2 bytes, some characters as 3 bytes, and some characters as 4 bytes. Characters with a value below 0x0080 are compressed to 1 byte, which works very well for characters used in the United States. Characters between 0x0080 and 0x07FF are converted to 2 bytes, which works well for European and Middle Eastern languages. Characters of 0x0800 and above are converted to 3 bytes, which works well for East Asian languages. Finally, surrogate pairs are written out as 4 bytes. UTF-8 is an extremely popular encoding format, but it's less efficient than UTF-16 if you encode many characters with values of 0x0800 or above. 

转载于:https://www.cnblogs.com/zhtf2014/archive/2010/12/16/1908630.html

你可能感兴趣的文章
WPF中Image显示本地图片
查看>>
Windows Phone 7你不知道的8件事
查看>>
脚本删除文件下的文件
查看>>
实用拜占庭容错算法PBFT
查看>>
java的二叉树树一层层输出,Java构造二叉树、树形结构先序遍历、中序遍历、后序遍历...
查看>>
php仿阿里巴巴,php实现的仿阿里巴巴实现同类产品翻页
查看>>
Node 中异常收集与监控
查看>>
七丶Python字典
查看>>
Excel-基本操作
查看>>
面对问题,如何去分析?(分析套路)
查看>>
Excel-逻辑函数
查看>>
面对问题,如何去分析?(日报问题)
查看>>
数据分析-业务知识
查看>>
nodejs vs python
查看>>
poj-1410 Intersection
查看>>
Java多线程基础(一)
查看>>
TCP粘包拆包问题
查看>>
Java中Runnable和Thread的区别
查看>>
SQL Server中利用正则表达式替换字符串
查看>>
POJ 1015 Jury Compromise(双塔dp)
查看>>