One of the mysteries of our age is why socialism continues to appeal to so many people. Whether in the Soviet Union, China, Eastern Europe, North Korea, Cuba, Vietnam, Cambodia or Venezuela, it has resulted in the suppression of free speech, the imprisonment of political dissidents and, more often than not, state-sanctioned mass murder. Socialist economics nearly always produce widespread starvation, something we were reminded of last week when the President of Venezuela urged people not to be squeamish about eating their rabbits. That perfectly captures the trajectory of nearly every socialist experiment: it begins with the dream of a more equal society and ends with people eating their pets. Has there ever been an ideology with a more miserable track record?

Why, then, did 40 per cent of the British electorate vote for a party led by Jeremy Corbyn last June? It wasn’t as if he acknowledged that all previous attempts to create a socialist utopia had failed and explained why it would be different under him. There was no fancy talk of ‘post-neoclassical endogenous growth theory’ or ‘pre-distribution’, as there had been by his two predecessors. No, he was selling exactly the same snake oil that every left-wing huckster has been peddling for the past 100 years, and in exactly the same bottle. He reminded me of a pharmacist trying to flog thalidomide to an expectant mother while making no attempt to hide the fact that it has caused the deaths of at least 2,000 children and serious birth defects in more than 10,000 others. And yet, nearly 13 million Britons voted for Corbyn. Could it be that they just don’t know about all the misery and suffering that socialism has unleashed?

That’s a popular theory on my side of the political divide and has prompted a good deal of head-scratching about how best to teach elementary history — such as that more people were killed by Stalin than by Hitler. One suggestion is to create a museum of communist terror that documents all the people murdered in the great socialist republics — and full credit to the journalist James Bartholomew for getting some traction behind this idea. But is it really historical ignorance that prompts people to invest their hopes in Corbyn? An inconvenient fact for holders of this theory is that those who voted Labour at the last election tended to be better educated than those who voted Tory.

To try and solve the puzzle of socialism’s enduring appeal, we have to turn to evolutionary psychologists and in particular Leda Cosmides and John Tooby, two of the leading thinkers in the field. They contend that we don’t come into the world as tabulae rasae, ready to take on the imprint of whatever society we happen to be born into. Rather, we are more like smartphones that come pre-loaded with various apps, including a set of moral intuitions. The problem is, these apps haven’t been updated for 40,000 years. They were designed for small bands of hunter-gatherers rather than citizens of the modern world and prompt us to look more favourably on socialism than free-market capitalism. Why? Because in hunter-gatherer societies, where the pooling of resources is essential for survival, the principle of ‘from each according to his ability, to each according to his need’ makes perfect sense. By the same token, we have a great deal of difficulty grasping that people acting in an individual, self-interested way can create huge communal benefits, as it does under capitalism. Back in the primeval forest, our survival depended upon distrusting people who weren’t willing to engage in reciprocal altruism.

In hunter-gatherer societies, goods are finite. If someone has more than his fair share of meat, there is less for everyone else. That’s not true of capitalist societies, where successful entrepreneurs such as Steve Jobs create wealth without taking anything away from others; but because we’re programmed to think of resources in a zero-sum way we cannot easily understand this. Instead, we’re inclined to believe people like Corbyn when they tell us the rich only got that way by stealing from the poor.

This zero-sum thinking doesn’t just explain why people cannot readily understand the concept of wealth being created under capitalism; it also explains why seeing people with more than us can lead to envy and resentment. We look at their lavish property and, on some primitive, hunter-gatherer level, believe they’ve only come by what they have by depriving us of what we’re entitled to. All property is theft. This thinking can often lead to a desire to tear down the person in question, to reduce their status so it’s level with ours. The anthropologist Christopher Boehm believes that this violent impulse underpins all egalitarian ideologies, which might explain why intellectuals, Jews and middle-class property owners are often interned in prison camps and/or put to death in socialist societies. (See Russia, China, Cambodia, etc.) Interestingly, Boehm points out that chimpanzees, with whom we share a common ancestor, are also prone to the same tall-poppy syndrome. I recommend his book Hierarchy in the Forest: The Evolution of Egalitarian Behavior if you want to learn more about the pathological roots of socialism.

So what’s the solution? Are we doomed to repeat the mistakes of the past? Hopefully not, but we need to tell a story about capitalism that is just as appealing to people’s 40,000-year-old moral intuitions as the sales patter of socialist snake oil salesmen.