main()
{
printf("\n %d %d %d",sizeof('3'),sizeof("3"),sizeof(3));
}
wat is the o/p and how?

Answer Posted / niru

2 2 2
it returns the size of the int.
if the compiler is 32bit, size of the int=4
o/p: 4 4 4
For example:
void main()
{
long int i;
clrscr();
printf("%d %d %d \n",sizeof(i),sizeof("3"),sizeof(3));
getch();
}
output:4 2 2

Is This Answer Correct ?    1 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Tell me with an example the self-referential structure?

566


What are the different types of errors?

646


What is the difference between exit() and _exit() function in c?

584


What is a 'null pointer assignment' error?

724


How do you declare a variable that will hold string values?

670






What is the use of sizeof () in c?

558


What is the difference between memcpy and memmove?

605


One of the Institutes contains 5 student groups. Every group contains 4 students. Institute wants to store student group’s details in array. Group should contain group member’s details (name and registration number and age), project name, and mark of the group.

2160


Which of the following operators is incorrect and why? ( >=, <=, <>, ==)

665


List out few of the applications that make use of Multilinked Structures?

1300


What is the concatenation operator?

610


Is it cc or c in a letter?

565


How can you determine the size of an allocated portion of memory?

745


What are # preprocessor operator in c?

632


How macro execution is faster than function ?

666