和#34;"之间有什么区别?和''在unsigned char name中=' 1&#39 ;; (" 1&#34)

时间:2016-05-05 17:46:22

标签: c char hex unsigned double-quotes

以下代码中单引号和双引号之间有什么区别:

    unsigned char name='1';
    unsigned char name1="1";
    printf("name in hex name=%x, name1=%x\n",name,name1);
    printf("name in ascii name=%d, name1=%d\n",name,name1);

输出如下:

 name in hex name=31, name1=18
 name in ascii name=49 name1=24

0 个答案:

没有答案