XORG (XOR PUBG)
CodeChefOpen on judge ↗
Ayush was jealous of PUBG expert Prince as he could not defeat him. Frustrated and devastated, he decided to invent a new game XORG. He invited Prince to his flat and asked him to play XORG. Ayush designed the game with $N$ houses, numbered from $1$ to $N$. Each house is associated with a damage value $D$. These houses form a $tree$ like structure where house $1$ is the hell house or in other wo
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.
Sign in to chat with the tutor and save your progress.
Sign in to start