What will be the output of the following C code?
#include <stdio.h>
struct p
{
unsigned int x : 7;
unsigned int y : 2;
};
int main()
{
struct p p;
p.x = 110;
p.y = 2;
printf("%d\n", p.x);
}
#include <stdio.h>
struct p
{
unsigned int x : 7;
unsigned int y : 2;
};
int main()
{
struct p p;
p.x = 110;
p.y = 2;
printf("%d\n", p.x);
}A. Compile time error
B. 110
C. Depends on the standard
D. None of the mentioned
Answer: Option B

Join The Discussion