CJCoding With Joseph
15free / daySign inCreate account

Size of a Struct

A struct Triple contains three int fields: a, b, and c. Print the number of bytes the struct occupies using sizeof (see Expected Output).

Each int is 4 bytes, so three of them total 12. Print the sizeof result with %zu (it is a size_t). There is no trailing newline.

Expected Output:

12

= newline. No newline after the last line.

Hints2 available
Topics:
Structs
1
Tab to indent (Esc then Tab to move on) · Ctrl+Enter to run · Shift+Alt+F to format · Ctrl+Space to expand shortcuts (p, fori)

Your Output

Run your code to see the output here...

Test Cases

Run your code to see test case results.