Find the output?
void main()
{float a=2.0;
printf("\nSize of a ::%d",sizeof(a));
printf("\nSize of 2.0 ::%d",sizeof(2.0));}
Answers were Sorted based on User's Feedback
Answer / aravind
ok guys.
Here ans is 4 and 4.
I think %d specifier is for integer and it takes a=2 and prints 4 bytes for gcc and 2 bytes for turbo. Sizeof(2.0) also takes %d integer specifier and prints 4.
Is This Answer Correct ? | 4 Yes | 1 No |
hello fnd..i am ricky dobriyal
output:-
Size of a =4
Size of 2.0=8 /* because of double*/
Is This Answer Correct ? | 1 Yes | 1 No |
Answer / manish soni tagore collage jai
here a as a float so 4bytes
and 2.0 is work as double.
when 2.0f work as a flaot so .
sizeof(2.0f)is 4 byte
Is This Answer Correct ? | 0 Yes | 1 No |
WAP TO ACCEPT STRING AND COUNT A COMES N TIMES B COMES N TIMES C COMES N TIMES D COMES N TIMES AND SO ON......... AT LAST UNTIL Z COMES N TIMES...............
What is static volatile in c?
what is difference between null and nul in c language
what is the difference between north western polytechnique university and your applied colleges?? please give ur answers for this. :)
How many types of sorting are there in c?
which types of data structure will i use to convert infix to post fix???
Are pointers really faster than arrays?
what is the need for main function in c?
without using arithmatic operator convert an intger variable x into x+1
Where is c used?
Is c an object oriented programming language?
why the execution starts from main function