add sizeof.c
This commit is contained in:
parent
165a3cd686
commit
6e8729df55
BIN
Code/hello
Normal file
BIN
Code/hello
Normal file
Binary file not shown.
7
Code/hello.c
Normal file
7
Code/hello.c
Normal file
@ -0,0 +1,7 @@
|
||||
#include <stdio.h>
|
||||
|
||||
int main()
|
||||
{
|
||||
printf("hello world\n");
|
||||
return 0;
|
||||
}
|
BIN
Code/sizeof
Normal file
BIN
Code/sizeof
Normal file
Binary file not shown.
17
Code/sizeof.c
Normal file
17
Code/sizeof.c
Normal file
@ -0,0 +1,17 @@
|
||||
#include <stdio.h>
|
||||
#include <stdbool.h>
|
||||
int main()
|
||||
{
|
||||
printf("int: %ld\n",sizeof(int));
|
||||
printf("float: %ld\n",sizeof(float));
|
||||
printf("double: %ld\n",sizeof(double));
|
||||
printf("char: %ld\n",sizeof(char));
|
||||
printf("long: %ld\n",sizeof(long));
|
||||
printf("long long: %ld\n",sizeof(long long));
|
||||
printf("short: %ld\n",sizeof(short));
|
||||
printf("void: %ld\n",sizeof(void));
|
||||
printf("bool: %ld\n",sizeof(bool));
|
||||
printf("unsigned int: %ld\n",sizeof(unsigned int));
|
||||
|
||||
return 0;
|
||||
}
|
8
Code/test.c
Normal file
8
Code/test.c
Normal file
@ -0,0 +1,8 @@
|
||||
#include<stdio.h>
|
||||
|
||||
int main()
|
||||
{
|
||||
printf("hello!");
|
||||
|
||||
return 0;
|
||||
}
|
Loading…
Reference in New Issue
Block a user