Guess who made it to the top of the Forbes billionaire rankings for 2016? It's the man who needs no introduction: Bill Gates. With an estimated net worth of $86.5 billion, the co-founder and former CEO of Microsoft has come a long way to become the richest man in the world today. Gates' friend and one of the world's most successful investors, Warren Buffett, comes in at a close second, with a net worth of $78.7 billion.

Gates' primary source of wealth has, of course, been Microsoft, but if you think he has parked the bulk of his money in Microsoft stock, you're as far from the truth as one can get. In fact, Microsoft isn't even part of the Bill & Melinda Gates Foundation Trust's 18-stock portfolio!

Words associated with philanthropy.

Bill Gates is a revered philanthropist. Image source: Getty Images.

Before I reveal which stocks belong in the charitable venture's portfolio, you should know that Gates is more than just a business magnate -- he is among the world's most revered philanthropists today. The Bill & Melinda Gates Foundation is testimony: As of the fourth quarter of 2015, it had made grant payments worth $36.7 billion since inception to combat diseases and alleviate poverty worldwide, among other social causes it champions. It's fascinating how a visit to Africa turned Gates toward philanthropy, but that's a story for another day. What's important to know is that Gates has been passing on a good chunk of his money to his foundation since establishing it with his wife, Melinda, in 2000.

Who manages Gates' money, and how?

This task is entrusted to wealth manager Michael Larson, who manages both Gates' personal wealth and the endowments of the Bill & Melinda Gates Foundation Trust via private firm Cascade Investments. Cascade doesn't publicly disclose its numbers, but the trust's portfolio can give you valuable insight into Larson's investment style -- or I might as well say Gates', as the endowments comprise Bill and Melinda's donated assets and Buffett's contributions.

Yes, you guessed it right: Buffett is one of the trustees of the Bill & Melinda Gates Foundation, which isn't surprising given that the organization really found its footing in 2006, when Buffett pledged $30 billion in Berkshire Hathaway (NYSE:BRK-A) (NYSE:BRK-B) stock, to be spread over years, to support Gates' philanthropic causes. As Bill and Melinda put it in the foundation's 2017 Annual Letter addressing Buffett, "It was the biggest single gift anyone ever gave anybody for anything. We knew we owed you a fantastic return on your investment." By "return," they mean all the ways they're helping improve lives across the globe.

It isn't an easy task, but Larson ensures that the endowments are primarily invested in stocks that can generate good returns to support the foundation's charitable goals.

The top five stocks the Bill & Melinda Gates Foundation Trust owns

While Bill and Melinda haven't disclosed their investment policies in detail, they're specific about not investing in "companies whose profit model is centrally tied to corporate activity that they find egregious," such as tobacco stocks. Their investing style, though, closely resembles that of Buffett's. In other words, the Bill & Melinda Gates Foundation Trust's portfolio is chock full of fundamentally strong companies with wide moats and sustainable competitive advantages. Most are dividend payers, too, much like Buffett stocks.

According to the latest update, the trust has about $19 billion invested in stocks, of which nearly $15.6 billion comes from just five companies. Here they are, ranked according to their weighting in the portfolio.

1. Berkshire Hathaway (59.43%)

That Berkshire Hathaway makes up a bulk of Gates' trust's portfolio shouldn't come as a surprise. Berkshire Hathaway is among the strongest companies around, with a well-diversified revenue stream, rock-solid balance sheet, track record of strong cash flows, and management's staunch commitment to growth. So, despite the conglomerate not paying any dividends, shareholders have reaped rich rewards over the years: The very first page of Berkshire Hathaway's latest annual report highlights the stock's 20.8% compounded annual gains since 1965. That translates into jaw-dropping overall gains of nearly 2 million percent during the period. Berkshire Hathaway will likely be the backbone of the trust's portfolio unless Buffett and Gates part ways.

2. Waste Management Inc. (NYSE:WM) (6.95%)

Waste Management's stock has more than doubled in the past decade, proving that trash can be valuable, too. While Waste Management's business of hauling, disposing, and recycling trash is resilient to business cycles, its unparalleled landfill network acts as a formidable barrier to competitors. Not surprisingly, Waste Management's margins were intact even during recessionary periods.

WM Operating Margin (TTM) Chart

WM Operating Margin (TTM) data by YCharts.

To top that, Waste Management has raised its dividend for 14 straight years, currently yielding 2.3% -- the highest among its peers. Today, Waste Management owns and operates the highest number of landfills, waste transfer, injection, and recycling facilities in the industry to serve more than 21 million customers across the U.S. and Canada, giving it a moat like no other. With the company also boasting best-in-class returns on invested capital of about 8%, it's no surprise the stock has made it into Gates' trust's portfolio.

3. Canadian National Railway (NYSE:CNI) (6.07%)

Railroad isn't the kind of industry to grow gangbusters, but the economy could come to a standstill if rail stops transporting goods. This "essential" nature of the business is perhaps why Buffett's Berkshire Hathaway bought Burlington Northern Santa Fe in its biggest deal ever in 2009, and why Canadian National Railway is in Gates' portfolio. Between Cascade Investments and the Bill & Melinda Gates Foundation, Gates is the largest shareholder in the Canadian railroad today.

Why Canadian National Railway, of all railroads? As the only transcontinental railroad in North America, spanning three key coasts over 20,000 miles of track, it has the widest coverage area among its peers. Canadian National is also the most efficient railroad as measured by the operating ratio, and it generates boatloads of cash flows, a good portion of which go to shareholders. It recently increased its dividend by 10%, marking its 21st consecutive year of dividend increases.

CNI Net Income (TTM) Chart

CNI Net Income (TTM) data by YCharts.

Best-in-class efficiency and margins, and double-digit returns on equity and invested capital, make Canadian National a great buy-and-hold stock, the type Buffett and Gates prefer.

4. Caterpillar Inc. (NYSE:CAT) (5.49%)

Gates recently told CNBC that he believes in "the philosophy that Warren Buffett has put forth that you can find great companies and invest in them, then the macroeconomics can go up and down and the basic value of what you are holding on to there will be maintained throughout that."

That explains why Caterpillar is part of the Bill & Melinda Gates Foundation Trust's investments despite the massive headwinds facing the company in recent years.

Caterpillar is the world's leading manufacturer of construction and mining equipment, diesel and natural gas engines, industrial gas turbines, and locomotives. This dominant position in a highly capital-intensive industry is a perfect ingredient for a moat, in addition to the indomitable brand image Caterpillar has built for itself during its 90 years of existence. The industry stalwart has even paid a dividend every year since 1925, currently yielding 3.3%. Caterpillar may not be in the best shape right now, but its leadership and brand power position it well to benefit tremendously as the mining and oil and gas sectors revive.

5. Wal-Mart Stores (NYSE:WMT) (4.22%)

With Buffett selling almost his entire stake in Wal-Mart in recent quarters, this is perhaps the most interesting of the top five stocks in the Bill & Melinda Gates Foundation's portfolio. Whether Larson will also exit the stock is anyone's guess, but why Wal-Mart made it into the portfolio in the first place isn't tough to figure out.

A couple buying groceries at a Wal-Mart store.

Image source: Wal-Mart.

With nearly $500 billion in sales, Wal-Mart is not only the largest retailer, but is the largest company in the world by revenue. Wal-Mart's commitment to shareholders is unquestionable: It's a Dividend Aristocrat, having raised its dividend for 44 straight years. The retailer has returned a whopping $55 billion to shareholders in the form of dividends and share repurchases over the past five years, and it yields 2.9% currently.

Wal-Mart is doing its part to catch up with the e-commerce wave, but Amazon is proving a tough nut to crack. However, Wal-Mart continues to generate solid free cash flows -- about $18 billion for the trailing 12 months -- and boasts double-digit returns on equity and invested capital. The road ahead may not be easy for Wal-Mart, but Larson isn't losing faith in the retailer just yet.

The bottom line

Clearly, stocks in Gates' trust are leaders in their own right. Going by the rich rewards shareholders in the above five stocks have reaped over the years, you may want to track the Bill & Melinda Gates Foundation Trust's investments going forward, if you aren't already doing so.