VOOZH about

URL: https://www.geeksforgeeks.org/aptitude/puzzle-20-5-pirates-and-100-gold-coins/

⇱ Puzzle | 5 Pirates and 100 Gold Coins - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Puzzle | 5 Pirates and 100 Gold Coins

Last Updated : 6 Jun, 2026

Five pirates, A, B, C, D, and E, discover a treasure chest containing 100 gold coins. They are ranked by seniority such that A is the most senior and E is the most junior.

Rules:

  • The most senior pirate alive proposes a distribution of all 100 coins.
  • All pirates, including the proposer, vote on the proposal.
  • A proposal is accepted if at least half of the pirates vote in favor.
  • In case of a tie, the proposer has the casting vote.
  • If the proposal is rejected, the proposer is eliminated, and the next senior pirate makes a new proposal.

All pirates are perfectly rational and always prioritize survival first. After that, they try to maximize their coins, and if outcomes are equal, they prefer fewer pirates alive.

What is the maximum number of gold coins Pirate A can keep while ensuring that his proposal is accepted?

👁 yu

Check if you were right - full answer with solution below.

Solution:

The solution becomes clear by working backwards:

  • Step 1: If only D and E remain
    D keeps all 100 coins, and E receives 0, since D’s vote alone is enough to pass the proposal.
  • Step 2: If C, D, and E remain
    C needs one additional vote. He offers 1 coin to E, as E would otherwise receive nothing in the next round.
    Distribution: C = 99, D = 0, E = 1
  • Step 3: If B, C, D, and E remain
    B needs one additional vote. He offers 1 coin to D, since D would receive nothing under C’s proposal.
    Distribution: B = 99, C = 0, D = 1, E = 0
  • Step 4: When A proposes
    A knows that under B’s proposal, C and E receive 0 coins. Therefore, A offers 1 coin each to C and E to secure their votes.
  • With these votes, A’s proposal is accepted while allowing him to keep the maximum number of coins

The final distribution is: A = 98, B = 0, C = 1, D = 0, E = 1

Comment
Article Tags: