Multiple ChoiceBeginner 45s
sizeof with padding
For `struct A { char c; int i; };`, on a typical 64-bit platform with 4-byte int, what is `sizeof(A)`?
Options
- 15 (1 byte char + 4 byte int).
- 26 (aligned to 2 bytes).
- 316 (aligned to the largest member twice).
- 48 (3 bytes padding after c to align i).
Think you can answer under pressure?
Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.