In 1513, Niccolò Machiavelli had just lost everything. He had served the Florentine republic for fourteen years as a diplomat and senior official, and when the Medici returned he was dismissed, imprisoned and tortured. On his release he withdrew to a small farm at Sant’Andrea in Percussina, a few miles from the city. In a famous letter to his friend Francesco Vettori he describes how he spent his days: in the morning, arguments at the inn and games of cards with the butcher and the miller; in the evening, at home, he took off his mud-stained clothes, put on the garments of the court and sat down to converse, in his mind, with the ancients, who answered him kindly. Out of those conversations came The Prince.

The book has a bad reputation, and to modern eyes it partly deserves it. It does, however, contain one chapter, the twenty-fifth, that is among the most lucid reflections ever written on uncertainty. In it Machiavelli asks how far the affairs of the world are governed by fortune and how much depends on us. His answer is that fortune is the arbiter of half our actions, but leaves the other half, or a little less, for us to govern.

To explain this, he uses an image. Fortune resembles one of those raging rivers that, when they burst their banks, flood the plains, tear up trees and buildings, and carry the earth from one place to another. Everyone flees before the flood and no one can hold it back. That does not mean, Machiavelli adds, that people can do nothing. When times are calm, they can build dykes and embankments, so that when the river rises again the water runs off through a channel, or its force is neither so unchecked nor so destructive.

The key word is virtù, which does not mean virtue in the moral sense. It is the capacity to act with energy, intelligence and foresight on the part of the world that is ours to shape. The idea is very concrete. Virtù is not shown during the flood, but before it. Dykes are built in fair weather, precisely when nobody sees the need for them.

Machiavelli makes a second observation, more uncomfortable still. The same behavior can lead to success in some circumstances and to failure in others. Pope Julius II always succeeded by acting impetuously, because the times favored him, but had times come that called for caution, he would have been ruined, because he would not have known how to change. The problem, Machiavelli concludes, is that people cling to the way of acting that has brought them success and cannot adapt when the times change.

In business, Machiavelli’s dykes have familiar names: cash reserves, a diversified customer base, teams trained in more than one role, contingency plans that someone has genuinely reviewed. All of them share a flaw. They look like a pointless cost when things are going well. That is why organizations cut them in the good years, which is exactly when they should be built. The second lesson is just as practical: the leadership style that made a company grow may be the one that brings it down when the context changes.

The same is true of our personal lives. The dykes are savings, health looked after before it fails, relationships kept up when we do not need them, skills learned before work demands them. No one can prevent the flood. What we can decide is how it will find us.

When it comes to learning, Machiavelli’s idea challenges the way we often prepare for the future: by trying to guess it. We put a great deal of effort into predicting which professions will have prospects or which technologies will prevail, and very little into building the capacity to adapt to whatever comes. At a time when artificial intelligence changes the rules every few months, learning how to learn is the strongest dyke we can raise.

We should not idealize Machiavelli. The same chapter ends with an image that is unacceptable today, that of fortune as a woman who must be subdued by force, and The Prince as a whole has been used to justify a great many unjustifiable things. Nor do we need to believe his arithmetic, since no one knows whether fortune’s share is half, more or less. What survives is the central intuition: uncertainty is no excuse for passivity, and the time to act is when it does not yet seem necessary.

This week’s exercise. Identify the river that could affect you most in the coming years: a crisis in your sector, a technological shift, the loss of an important client, an unexpected family event. On a sheet of paper, write down which dykes you already have against that flood and which you lack. Then choose one, just one, that you can start building this month, while the weather is fair.

Which dyke are you putting off building because, today, the river is calm?

Sapere aude.