consider the following structure:
struct num nam{
int no;
char name[25];
};
struct num nam
n1[]={{12,"Fred"},{15,"Martin"},{8,"Peter"},{11,Nicholas"}};
.....
.....
printf("%d%d",n1[2],no,(*(n1 + 2),no) + 1);
What does the above statement print?
a.8,9
b.9,9
c.8,8
d.8,unpredictable value

Answer Posted / jai

Compilation error. Otherwise if rewritten printf statement
is:
printf("%d,%d", n1[2].no, (*(n1+2).no)+1);
then answer is a. 8,9

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is #include cctype?

580


please send me the code for multiplying sparse matrix using c

1726


What is union and structure?

574


can anyone please tell about the nested interrupts?

1678


I have a varargs function which accepts a float parameter?

579






How can I sort more data than will fit in memory?

630


What is a null pointer in c?

596


What is structure packing in c?

608


Why c language is called c?

571


How would you rename a function in C?

622


What is keyword with example?

642


Write a C Program That Will Count The Number Of Even And Odd Integers In A Set using while loop

1717


How can I invoke another program (a standalone executable, or an operating system command) from within a c program?

653


Without Computer networks, Computers will be half the use. Comment.

1877


What will the preprocessor do for a program?

592