← All problemsSign in

Stand Up

A classroom at the Academy of Bit Wizardry contains N rows of chairs. Each row, contains exactly M chairs. Each chair is expected to be filled by exactly one student; you may assume no chair is ever empty. Curiously, N*M is guaranteed to be an even number. This means there are always an even number of students in a class. The students come to the Academy of Bit Wizardry from (N*M / 2) coutries. I

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start