What will be the size of these structures?

			  		

Loading

โœช Choose the correct option.

What will be the size of these structures?


#include
struct S1 {
char c;
int i[2];
double v;
} SA1;
struct S2 {
double x;
int i[2];
char c;
} SA2;
int main()
{
printf("
sizeof S1 %d : Sizeof S2 %d ",sizeof(SA1),sizeof(SA2));
return 0;
}

Note:char takes 1 byte, int takes 4 bytes, double takes 8 bytes

A. sizeof S1 12 : Sizeof S2 12
B. sizeof S1 20 : Sizeof S2 20
C. sizeof S1 13 : Sizeof S2 13
D. Compilation Error