Vidyalelo
C Programming · Q8

Structure and Union

Programming · C Programming · question 8

Q8

Which statement correctly defines a structure named "Person" with members "name" and "age" of type char* and int respectively?

A.
struct Person { char* name; int age; }
Answer
B.
struct Person { name, age; }
C.
struct { name; age; } Person;
D.
struct { char* name, int age; } Person;

Answer: Option A

Solution

Answer: Option A
No explanation is given for this question Let's Discuss on Board