Five pirates, fresh from their first bout of pillaging, return to their island base to celebrate and divide up the treasure.
While this was their first time working together, the start of what they all hoped would be a long and profitable partnership, they were all well versed in the habits and hazards of their chosen profession. True to tradition, they had established before the raid a pecking order amongst themselves, ranked first to fifth. That night, they would celebrate, drown themselves in rum and party until they passed out, then in the morning the first ranked pirate would propose a splitting of the coins between them. In the event that the split was rejected by the majority, they would be forced to walk the plank, and the second ranked pirate would propose a split himself, continuing thus until no conflict, or no pirates, remained.
That evening, they made a big bonfire as planned and broke out the rum, counting their treasure - a shining 100 gold coins! - and regaling each other with boasts and stories until the fire burned low, and they split up to sleep.
Later that night, the third pirate was woken by a sharp nudge to the small of their back. Blinking blearily, they made out the fifth and fourth pirate's faces in the darkness.
"Listen third," the fifth pirate said, "fourth and I have been thinking about how we plan to vote tomorrow, and wanted to include you in our conspiracy."
The third pirate furrowed their brow. "What's to conspire about? This problem's more or less solved. If you two killed me, second and first, then fourth would take the money for themselves, so anyone can buy your vote for a coin. Which any of us but fourth would do, since it's not worth dying just over a gold coin or two. First can't buy second's vote, since they can't lose out by voting against him, and second can't buy mine for the same reason and so on. First needs my vote to beat second, so you and I get one coin each and first gets the rest."
The fifth pirate grinned. "Sure, that's the naive solution. But it seems kind of a raw deal for second and fourth, yeah? Not that we get it much better, getting only the one coin each of us."
The fourth pirate frowned. "Whether or not it's a raw deal doesn't come into it. That's the only logical solution, it's basic game theory."
"Not so! See, that chain of logic ignores that, assuming our continued good fortune, this is an iterated game! And it didn't allow for the little chat we're having right now either. You see, me and fourth have a proposition for you."
The fifth and the third shuffled off to where the fourth was waiting, and all three pirates gathered around a diagram they had drawn in the sand. A few frenzied minutes of whispering later, they had come to their agreement.
"I understand why you needed to wake me up to decide this now," the third pirate said. "This could work out nicely for the three of us." They thought a moment longer, then frowned. "How do we make sure that the first proposes this split? Are you going to wake him up next?"
The fourth pirate shook their head. "Nah, not worth the effort. We'll tell the first and second in the morning. It's the first who has the least power out of all of us after all. Just needed to make sure you were on board before we moved forward with this. As we explained, you're not any better off betraying us."
The third nodded, then they all went back to their beds. The following morning, they explained their scheme to the first and second pirates, and while the first pirate was rather disappointed the second was quite pleased. They proceeded to have a somewhat longer and happier career than more strictly traditional pirates until they all died of scurvy some months later.
For those who find stories tiresome, the puzzle is the classic five-pirates-dividing-100-gold with the twists that the game is iterated and the pirates can discuss their choices among themselves before voting. How does the gold end up divided?
Some hints, some of which are intentionally given away by the story:
Hint 1:
None of the five pirates are voted off the plank.
Hint 2:
Every pirate (except the first) is better off in both the short term (immediate gold) and long term (cumulative gold) than they would be following the 'traditional' solution. There are better solutions in the short term for some pirates, but none in the long term (Unless I've messed up horribly...).
Hint 3:
I mention in the story that the first pirate is the least powerful of the group, but they are not completely powerless. Interestingly, they only have power over the third pirate, who is otherwise the most powerful of the pirates.