← All problemsSign in

No equal guest pair

2020 is going to end and everyone wants to enjoy the new year party. But the party has to follow some rules: The whole hall is divided into $N$ rooms, rules are: $1.$ Number of people in $Room$ $i$+Number of people in $Room$ $j$ ≠ Number of people in $Room$ $p$ $2.$ Total number of people in the hall has to be ( $2$ $to$ $the$ $power$ $of$ $N ) $-$1$. $3.$ Number of people in rooms h

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