-
What will be the output of the following C code?
#include <stdio.h>
struct Z
{
char *name;
struct Z *next;
};
struct Z *ptrary[10];
int main()
{
struct Z z;
z.name = "Raj";
z.next = NULL;
ptrary[0] = &z;
printf("%s\n", ptrary[0]->name);
return 0;
}
-
- Compilation Error
- Garbage value
- Raj
- Undefined behaviour
- None of these
Correct Option: C
Raj