← All problemsSign in

Favourite Numbers

CodeChefRating 477Open on judge ↗

- Alice likes numbers which are even, and are a multiple of 7. - Bob likes numbers which are odd, and are a multiple of 9. Alice, Bob, and Charlie find a number $A$. - If Alice likes $A$, Alice takes home the number. - If Bob likes $A$, Bob takes home the number. - If both Alice and Bob don't like the number, Charlie takes it home. Given $A$, find who takes it home. **Note:** You can prove tha

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