Big-Endian and Little-Endian

Big-Endian and Little-Endian


int  _tmain( int  argc, _TCHAR *  argv[])
{
    
long  s = 0x6E7C ;
    
char   * pc = ( char * ) & s;
    printf(
" \n%02X%02X\n " , * pc, * (pc + 1 ));   // 7C6E
    getchar();
    
return   0 ;
}

你可能感兴趣的:(Big-Endian and Little-Endian)