The expression such as:
- sizeof object
- sizeof(type name)
Example :
#include<stdio.h>
int main()
{
printf("size of int in byte : %d\n", sizeof(int));
printf("size of char in byte %d\n", sizeof(char));
printf("size of float in byte %d", sizeof(float));
return 0;
}
Output :
size of int in byte : 4 size of char in byte 1 size of float in byte 4
No comments:
Post a Comment