An Austrian holiday led to iterated cooperation between Karl Sigmund (left) and Martin Nowak.

Once a year, the theoretical chemist Peter Schuster took his students from the University of Vienna to a small house in the Austrian mountains. During the day we skied, of course, but in the evening the emphasis was on science. I was a first-year PhD student looking for a project. The mathematician Karl Sigmund was there and gave a talk on what was a new topic for him: the prisoner's dilemma. At the end of the talk I asked a question, and the next day Karl and I travelled back to Vienna, endlessly debating this game. In subsequent days, I visited his office and we started to do calculations. We had become prisoners of the dilemma.

I was amazed that mathematics could be used to explore the evolution of social interactions. In the prisoner's dilemma, two players have a choice between cooperation and defection. If both cooperate, they get more than if both defect. But if one cooperates while the other defects, the cooperator gets the lowest score and the defector the highest. This is the dilemma. In a single game, defection is an unbeatable strategy. The game becomes complicated and fascinating, however, if repeated. In his talk on the mountain, Karl reported that a simple strategy, tit-for-tat (TFT), was victorious in two ‘world championships’ conducted by Robert Axelrod. Researchers from many disciplines had submitted computer programs to play the repeated prisoner's dilemma in a round-robin tournament. The surprise winner of the first tournament was the simplest of all strategies, TFT, submitted by game theorist Anatol Rapoport. For the second tournament, others attempted to enter strategies that were superior to TFT, but Rapoport (following the maxim of British soccer leagues, ‘Never change a winning team’) once more fielded TFT, and again it won.

TFT cooperates on the first move and then copies whatever the opponent did in the previous round. Immediately, we noted that this strategy would be weak if errors were taken into account. Hence, we wanted to calculate a new world championship that was run by evolutionary dynamics in the presence of mistakes. Instead of a single round-robin tournament, there was a biological population of strategies evolving over many generations. Successful strategies left more offspring for the next generation. All strategies were stochastic: they had ‘trembling hands’ when implementing their rules.

Before encountering Karl, my speciality had been in biochemistry. I had wanted to study medicine since high school — which pleased my parents. But in the last vacation before university, I realized that my passion was to understand the natural laws of living systems, and I switched from medicine to biochemistry. My parents consulted a dictionary and discovered that biochemists work with yeast, which was also used for fermentation. They were worried about my future. At university, I found labs disappointing — experiments failed for no good reason. But theory was beautiful. You could do theory while walking through the forest or lying in the grass. Theory was not grey, but a golden tree of life.

My collaboration with Karl continued, and embarrassingly I had to tell my parents I was now working on games. The mathematical institute of the University of Vienna was in the same building as the priests' seminary and was filled with tranquillity and solemn peace. My impression was that people in those halls certainly contemplated distant and far greater worlds.

The institute had only two computers that students could use, but these were sufficient, and I was usually alone in the computer room. Karl gave all his lectures from memory. He never carried anything with him except one folded piece of paper that contained a long password and detailed instructions for how to switch on a computer. Mathematicians were in a different league, I concluded.

We often met in coffee houses, the genius loci of past glory. Here Kurt Goedel announced his incompleteness theorem, Ludwig Boltzmann worked on entropy, and Ludwig Wittgenstein challenged the Vienna circle. Or we walked in the Vienna Forest, visiting a meadow called ‘Himmel’ (Heaven), where a sign noted that here Sigmund Freud first understood the nature of dreams.

Within a year, we had conceived an evolutionary description of probabilistic strategies in the prisoner's dilemma struggling for cooperation by natural selection (see Nature 355, 250–253, 1992; Nature 364, 56–58, 1993). The prevailing paradigm, tit-for-tat, an unforgiving retaliator, was replaced by generous tit-for-tat (which always cooperates when the other person has cooperated and sometimes even when the other person has defected) and later by win–stay, lose–shift (which stays with its current choice if the score is above an aspiration level and changes otherwise). A by-product of this work was adaptive dynamics, representing a new way to look at the evolution of strategies in a continuous space. I handed in my thesis and asked Karl what to do next. He said Robert May was second to none in theoretical biology, and a few days later my train left for Oxford.

My introduction to Karl Sigmund in the Austrian mountains was the turning point that brought together mathematics and biology. But it was not the only time that my thinking or approach to science has changed course. Far from a linear path, my scientific career feels more like brownian motion, which is continuous everywhere, but differentiable nowhere. There have been many turning points that have sent me off in new directions, making me forget what I had been doing at the time.

I am no longer embarrassed to work on games. They are the generic description of evolutionary interactions among genes, cells and people. Children love games. Scientific creativity is to never stop playing.