添加bases.c

This commit is contained in:
LingZhaoHui 2021-10-06 14:49:11 +08:00
parent a25f190df3
commit 4f6d9843b0

9
chapter3/bases.c Normal file
View File

@ -0,0 +1,9 @@
#include <stdio.h>
int main(){
int x = 100;
printf("dec = %d;octal = %o, hex = %x\n", x, x, x);
printf("dec = %d;octal = %#o, hex = %#x\n", x, x, x);
return 0;
}