main()
{
printf("\n %d %d %d",sizeof('3'),sizeof("3"),sizeof(3));
}
wat is the o/p and how?
Answer Posted / k.thanigaivel
This output is
4 2 4
Explanation:
sizeof('1 or 2 or 3,......or n')=4
sizeof("0")=2
sizeof("10")=3
sizeof("100")=4
sizeof("1000")=5
sizeof("10000")=6
.
.
.
.
.
sizeof("n")=n
sizeof(1 or 2 or 3......or n)=4
| Is This Answer Correct ? | 27 Yes | 25 No |
Post New Answer View All Answers
what is a constant pointer in C
Is null always defined as 0(zero)?
How to get string length of given string in c?
Write a code to generate a series where the next element is the sum of last k terms.
What do you understand by friend-functions? How are they used?
What are the types of pointers?
What are near, far and huge pointers?
What is time null in c?
Why is c still so popular?
What are structural members?
How can I change their mode to binary?
What's the best way of making my program efficient?
Why use int main instead of void main?
How would you rename a function in C?
Explain what is the benefit of using const for declaring constants?