用sizeof来求数据类型所占内存大小
include<stdio.h>
int main()
{
int a;
char b;
double c;
printf("%d\n",sizeof a);
printf("%d\n",sizeof b);
printf("%d\n",sizeof c);
printf("%d\n",sizeof(int));
printf("%d\n",sizeof(char));
printf("%d\n",sizeof(float));
printf("%d\n",sizeof(double));
printf("%d\n",sizeof(short));
printf("%d\n",sizeof(long));
return 0;
}