- #include <stdio.h>
- int main()
- { signed int y = -12;
- signed t =-10;
- unsigned int p = 12;
- unsigned q =10;
-
- printf("%d\n",y );
- printf("%d\n",t );
- printf("%u\n",p );
- printf("%u\n",q );
-
- return 0;
- }
复制代码
打印的结果是:-12
-10
12
10
打印的结果正常,但是前面在unsigend后面加了负号应该报错的啊! |