What will be the output of the following C code?
#include <stdio.h>
struct student
{
char *c;
struct student point;
};
void main()
{
struct student s;
s.c = "hello";
printf("%s", s.c);
}
#include <stdio.h>
struct student
{
char *c;
struct student point;
};
void main()
{
struct student s;
s.c = "hello";
printf("%s", s.c);
}A. hello
B. Nothing
C. Varies
D. Compile time error
Answer: Option D
Related Questions on Structure and Union
Which of the following can be a member of a structure?
A. Function
B. Another structure
C. Enumeration
D. All of the above

Join The Discussion