Loot Split

Medium · rating 1250 · Math

Read coins and pirates. If the loot is split as evenly as possible, print two numbers: the most any single pirate receives and the least.

Constraints: 1 ≤ pirates ≤ coins ≤ 1012

Related problems

Open Loot Split in Code Arena →