Pergunta de entrevista da empresa Ciena

struct A{ int a; double b; char c; char* d; int* e; } sizeof(A) == ?

Resposta da entrevista

Sigiloso

25 de nov. de 2022

1. Depending on the system int might have different sizeof() what the value in your system is. 2. Pointers, no matter what type of pointer is, have the same value of ... 3. Do I need to consider Alignment issues like padding and packing which depend on the compiler 4. then add them together P.S.I feel this is the hardest question in all these rounds because Alignment is easy to miss