

MCQOPTIONS
Saved Bookmarks
1. |
What will be the output of the following C code?#include <stdio.h> struct B { char *name; struct B *next; }; struct B *ptrary[10]; int main() { struct B b; b->name = "Raj"; b->next = NULL; ptrary[0] = &b; printf("%s n", b->name); return 0; } |
A. | Compilation Error |
B. | Raj |
C. | Garbage value |
D. | Undefined behaviour |
E. | None of these |
Answer» B. Raj | |