ProgrammingVery hard

What is printed by printf("%d", 7 * 13 % 5 * 3 % 4);?

  1. A. 1
  2. B. 3
  3. C. 2
  4. D. 0

Correct answer: B. 3

The operators * and % have equal precedence and group left to right: 91 % 5 = 1, times 3 is 3, and 3 % 4 = 3.

More C Programming questions

Exams that ask this topic