If I'm getting different outputs on different compilers while running the below program:
#include <stdio.h>
void main()
{
struct s
{
int a;
char b;
} s1, s2;
int x = sizeof(s1);
printf("%d", x);
}
OUTPUT (Turbo c):
(int 2 + char 1 = 3)
I am getting 3 here.
OUTPUT (Code blocks):
8
Why is 8 is output here?