Vidyalelo
C Programming · Q46

Structure and Union

Programming · C Programming · question 46

Q46

What will be the output of the following C code? #include typedef struct p int x, y; k; int main() struct p p = 1, 2; k k1 = p; printf("%d ", k1.x);

A.
Compile time error
B.
1
Answer
C.
0
D.
Depends on the standard

Answer: Option B

Solution

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