ProgrammingModerate

int grid[4][4] is filled by grid[i][j] = i * j. What is grid[3][2]?

  1. A. 5
  2. B. 12
  3. C. 6
  4. D. 9

Correct answer: C. 6

grid[3][2] holds i * j = 3 * 2 = 6; indices are 0-based, so row 3 is the fourth row. 5 adds the indices instead of multiplying, 12 treats them as 1-based (4 * 3), and 9 squares the row index.

More C Programming questions

Exams that ask this topic