In 1991 there were about 270 billionaires in the world. Today there are more than 1,600, and 290 were added to the rolls in the past year alone. In other words, more people became billionaires in the past year than the entire number of billionaires in 1991.

A negative person might say that’s further evidence the rich are getting richer. A positive, go-getting person would say, “well, it’s easier to become a billionaire than ever before!” And it is.

I’ve made a comprehensive study of self-made billionaires and their (economic) secrets. Here, I review a couple of closely-related secrets, and some implications for entrepreneurs.

1. Spin laws into gold

When Bill Gates founded Microsoft, there were no intellectual property rights protections for software. Until the late 1980s, software could not be patented reliably. In the 1970s, software couldn’t even be copyrighted. Someone could take your code and copy it, word for word, and that was perfectly legal.

Bill Gates was therefore entering the technological equivalent of the Wild West. But here he had one crucial advantage, compared to all the other technology CEOs of the day: his father was a lawyer. Gates was able to draw up contracts, many of which set industry standards, which enabled him to establish property rights to his software – to make credible legal threats against anyone who used his software without paying.

Eventually, enforceable intellectual property rights for software became a mainstream phenomenon. But Microsoft was the leader. Not always a leader in innovation – the company lagged in multitasking, graphical user interfaces, networking, the internet, mobile computing…but always a leader in establishing legal protections for its products.

Lessons for entrepreneurs

Generally speaking, entrepreneurs have an instinctive and negative reaction to bureaucracy and regulation. The best place to do business, they tend to think, is a place where there is little or no regulation; anything that stands between them and the realization of their business goals is the enemy.

So why, then, did Bill Gates make such a determined effort to build regulation where none had existed?

Essentially, as a barrier to competition. Building great software is important, obviously, for a software business. But most companies that built great software in the early days of computing are now gone – remember WordPerfect? Remember VisiCalc? Remember Lotus Notes? It didn’t take long for other companies to reverse-engineer their products and build competing software.

You can develop as many great products as you want – if anyone can copy you without restriction, you’ll make no money in the marketplace. Market entry without restriction is a condition economists describe as “perfect competition,” and under those conditions, in the long term, profits are just about zero.

Taking it back to the topic of law and regulation: a counterintuitive but important point is that many of the most highly-regulated industries (for instance, pharmaceuticals) tend to have the highest average long-term rates of profitability (pharmaceuticals has been, in every decade since the 1960s, the US industry with the highest average return on invested capital, according to McKinsey).

Yes, bureaucracy and regulation are an obstacle to your business dreams; but they will also be an obstacle to any competitors who come after you. The extensive regulation of pharmaceuticals – not just of patents but also of product safety, product testing, and so on – create barriers to new entrants that produce that long-term profitability.

For that reason, it’s well worth thinking about “spinning laws into gold.” If it just so happens that you can establish the legal precedents that will govern your industry – like Bill Gates – so much the better.

2. The worst place to do business is really the best

Most business people are instinctively attracted to the largest, most lucrative markets.

They see a number with a lot of zeros at the end and it overwhelms their common sense. They think that if they can get even a little bit of that huge sum of money, they will be rich. Following this line of reasoning, they conclude that going global is the ultimate achievement of business strategy, because going global increases the number of markets they are in.

They are totally wrong. Yes, going for a huge market is tempting, but then you will be forced to price competitively and probably won’t make much money. You might have a significant share of a huge market, but it won’t be worth much.

It is much better to go for a huge share of a tiny market. There, you can turn the screws.

Dhirubhai Ambani, founder of the Reliance corporate empire in India and for many years that country’s richest man, built his business not only in a country where doing business was a serious challenge, but in perhaps the most difficult industry in that country. He started a business in the textile sector, which was at the time restricted to only small entrepreneurs.

Ambani knew that if he could somehow overcome these restrictions, and build a business empire in textiles, the oppressive restrictions would prevent most would-be competitors from following him.

It was, to be sure, a small market, at least at first. But while giant chemical firms like AkzoNobel and ICI were earning margins of under 5% as they slugged it out in the global marketplace, Ambani was making 15% margins for decades.

And, over time, Ambani’s tiny company, Reliance, became the largest company in India.

Lessons for entrepreneurs

Entrepreneurs tend to think in the first instance about producing something that others will want. After all, if there is no market need for your product or service, your company is not going anywhere.

But the people who have become the world’s billionaires have tended to think two steps ahead. They think: what can I produce that people will want? But also: how can I ensure that no one else will be able to replicate what I have done?

The basic logic here is very similar to what I described above for the pharmaceutical industry: any barriers to your entry are going to be barriers to the entry of others. This means in a place where it’s hard to do business, you can earn a fairly healthy margin before attracting any competitors at all; and in truly deplorable business environments, like the textiles industry in India when Ambani got his start, you may find yourself alone in the market, or with one or two competitors.

That’s a long way from the nightmare of perfect competition – and one reason I say: the worst place to do business can really be the best.

Sam Wilkin’s book, Wealth Secrets of the One Percent, is out now, published by Little, Brown in the US and Sceptre in the UK. He is a senior advisor to Oxford Economics, one of the world’s leading economic forecasting firms, and Oxford Analytica, a geopolitical analysis and advisory consultancy.