Cards/Game TheorySep 13, 2026

Four Lines Beat Everyone

Axelrod's 1980 Iterated Prisoner's Dilemma tournament, Rapoport's four-line Tit for Tat and its four traits, its second win against 62 entries, and the caveat that the result was setting-dependent

In 1980, a four-line program beat every strategy game theorists could invent. So they ran the tournament again, with everyone knowing who had won. It won again.

Robert Axelrod invited researchers to submit programs to play the Iterated Prisoner's Dilemma. The entries were elaborate — modelling opponents, bluffing, probing, layers of logic. The winner, submitted by Anatol Rapoport, was this:

def tit_for_tat():
    yield 'C'                  # move one
    while True:
        yield opponent_last_move

Cooperate on the first move, then copy whatever the other player just did. That's the entire strategy. The second tournament drew 62 entries, every one of them having watched it win, and it took that one too.

Axelrod found four traits behind the result. Never defect first. Retaliate immediately. Forgive instantly. Stay predictable enough to be trusted.

The honest caveat is that later research showed its success depends on the tournament's design — number of rounds, opponent mix, scoring. In Axelrod's setting it was the best available answer, which is a smaller claim than a law of nature.

The lesson survives anyway. Tit for Tat never out-thought anyone. It just behaved well: cooperative, firm, and forgiving.

Nobody could beat it. Everybody could have written it.

Nobody could beat it. Everybody could have written it.