how to find the size of the data type like int,float
without using the sizeof operator?
Answer Posted / amit prakash
main()
{
int a;
int *aa,*bb;
int size;
aa = &a;
bb=aa;
bb++;
size=bb-aa;
printf("\nsize_of_int:%u",size) ; // actual size but
depends upon compiler
}
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Difference between macros and inline functions? Can a function be forced as inline?
Is it better to use malloc() or calloc()?
How will you divide two numbers in a MACRO?
What is "Hungarian Notation"?
Explain how does free() know explain how much memory to release?
Explain what is the advantage of a random access file?
Why C language is a procedural language?
can we change the default calling convention in c if yes than how.........?
How to check whether string is a palindrome, WITHOUT USING STRING FUNCTIONS?
What is file in c language?
What is getch c?
What are structures and unions? State differencves between them.
What is the purpose of scanf() and printf() functions?
Explain what is the best way to comment out a section of code that contains comments?
Explain null pointer.