OUTCRY

// BRAIN TEASERS

Screwy Pirates: Puzzle and Step-by-Step Solution

  • Game Theory
  • Medium
  • Reported at Jane Street, SIG, Citadel, Optiver

The puzzle

Five pirates split 100 gold coins. The most senior pirate proposes a split and everyone votes, the proposer included. If at least half vote yes, the split stands; otherwise the proposer is thrown overboard and the next most senior pirate proposes. Every pirate is rational, wants to survive first and maximise gold second, and would rather see a rival go overboard when the gold is equal. What does the senior pirate propose?

Short answer: The senior pirate keeps 98 coins and gives 1 coin each to the third and the first (most junior) pirates: 98, 0, 1, 0, 1.

Step 1: Number the pirates and start from the smallest crew

Call the most junior pirate P1 and the most senior P5. A five-pirate problem is hard to see directly, but a one-pirate problem is trivial, and every larger case only needs to know what happens in the case one smaller. That is backward induction: solve the end of the game first and walk forward.

With one pirate, P1 proposes 100 coins to himself and votes yes. Done. With two pirates, P2 proposes 100 for himself and 0 for P1. P2's own vote is half of two votes, and at least half is enough, so the proposal passes. P1 is powerless: he gets nothing whatever he votes.

Step 2: Three and four pirates: buy the cheapest vote

With three pirates, P3 needs two yes votes, his own plus one more. He looks at what each pirate would get if he were thrown overboard: in the two-pirate game P2 gets 100 and P1 gets 0. P2 cannot be bought for anything less than 100, but P1 is better off with 1 coin than with 0. So P3 proposes 99 for himself, 0 for P2 and 1 for P1, and the vote passes 2 to 1.

With four pirates, P4 needs two votes out of four. In the three-pirate game P2 gets 0, so P2 is the cheapest vote: one coin. P4 proposes 99, 0, 1, 0 (reading P4, P3, P2, P1), and with his own vote plus P2's that is exactly half, which passes.

Step 3: Five pirates: two bribes of one coin

P5 needs three votes out of five, so he must buy two. In the four-pirate game P3 and P1 both get 0. Each of them strictly prefers 1 coin to the 0 they would get after P5 drowns, so each costs exactly one coin. P5 proposes 98 for himself, 0 for P4, 1 for P3, 0 for P2 and 1 for P1. P5, P3 and P1 vote yes, three votes out of five, and the split passes.

Notice who gets paid: the pirates who would be left with nothing in the next game down. The bribe is always the minimum that beats their outside option, and their outside option is zero.

Step 4: The general formula and where it fails

The pattern continues: with n pirates the proposer keeps 100 minus floor((n - 1) / 2) coins and gives one coin to each pirate who would get nothing in the (n - 1)-pirate game: the pirates two, four, six and so on places below him. So the proposer's share falls by one coin for every two extra pirates.

The pattern holds up to 200 pirates, where the proposer must give away all 100 coins and keeps nothing. Beyond that the proposer cannot buy enough votes with coins, and the analysis turns on which pirates would vote to save the proposer purely to save their own skins later, which is the follow-up interviewers like to ask after the five-pirate case.

Why interviewers ask it

Interviewers are listening for the method, not the 98: start from one pirate, state each pirate's outside option, and bribe the cheapest votes. Say the tie-break rule out loud, because 'at least half' versus 'more than half' changes the answer.

Screwy Pirates is the free Outcry simulator: no account, no card. Play it now, then see how you hold up on the timed screens.

Related Firm Questions

Firm names show where candidates report meeting this puzzle or a close variant. Outcry is not affiliated with any firm named here.