ProgrammingModerate

int m[2][5]; printf("%zu", sizeof m[0]); What is printed on a platform with 4-byte int?

  1. A. 5
  2. B. 20
  3. C. 10
  4. D. 40

Correct answer: B. 20

m[0] is one row of five ints, so 5 x 4 = 20 bytes. sizeof m would be 40.

More C Programming questions

Exams that ask this topic