What is the primary difference between a structure and a union in C?
What will be the output of sizeof(union test) if union has members: int a, char b, float c?
Which keyword is used to define a structure in C?
What is the size of the following structure?
struct point { int x; int y; float z; };
Can we pass a structure variable to a function in C?
Advertisement
What happens when you initialize a structure variable without assigning values?
Which of the following correctly declares a pointer to a structure?
What is the difference between struct and typedef struct?
What will be printed?
struct s { int a; char b; int c; }; printf("%lu", sizeof(struct s));
How do you access a member of a structure using a pointer?
What is the purpose of padding in structures?
Consider: union u { int x; double y; }; What is sizeof(u)?
Which statement is true about nested structures in C?
What happens if you assign a union member and then access another member?
struct u { int a; char b; }; u.a = 257; printf("%d", u.b);
How can you initialize a structure array of 10 elements partially in C?
What is the difference between self-referential and recursive structures?
Given union test { int x; char y[4]; }; If you set y[0]=65, y[1]=66, what happens to x?
Which of the following is a key difference between struct and union in C?
What will be the output of sizeof() for the following union? union data { int a; float b; double c; }
In C, what is a self-referential structure?