Apples and oranges
Rushitote went to a programming contest to distribute apples and oranges to the contestants. He has $N$ apples and $M$ oranges, which need to be divided **equally** amongst the contestants. Find the maximum possible number of contestants such that: - Every contestant gets an equal number of apples; and - Every contestant gets an equal number of oranges. Note that every fruit with Rushitote *mu
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