判断计算机的字节存储顺序--big endian or little endian?

short usData = 0x1122;
char  *pucData = (char*)&usData;
bool bBigEndian = (*pucData == 0x22);
posted @ 2008-07-01 16:38  能巴  阅读(417)  评论(0编辑  收藏  举报