C Programming and Technical

output??
main()
{i
nt i=400,j=300;
printf("%d..%d");
}

A. 400..300

Explanation: printf takes the values of the first two assignments of the program. Any number of printf's may be given. All of them take only the first two values. If more number of assignments given in the program,then printf will take garbage values.

Read Solution (Total 0)

C Other Question

output?
void main()
{
char far *farther,*farthest;
printf("%d..%d",sizeof(farther),sizeof(farthest));
}

A. 4..2

Explanation: The second pointer is of char type and not a far pointer
output??
main()
{
char *p;
p="Hello";
printf("%cn",*&*p);
}

A. H

Explanation: * is a dereference operator & is a reference operator. They can be applied any number of times provided it is meaningful. Here p points to the first character in the string "Hello". *p dereferences it and so its value is H. Again & references it to an address and * dereferences it to the value H.