Editor's note: This article has been corrected. Chipotle has 3,100 restaurants.

Like it or not, the stock market goes through bull and bear cycles. While the upturns can be very enjoyable, the downturns are often hard to stomach. That is unless you go in with a buy list of great companies you've wanted to own if only they were cheaper.

In other words, if you prepare yourself ahead of time for what are inevitable bear markets, you'll be ready to pounce on a bargain stock while others are fearful. Some names you might want to have on your buy list are Walmart (WMT 0.45%), Procter & Gamble (PG 0.01%), and Chipotle Mexican Grill (CMG 4.11%). Let's find out a bit more about these three top stocks.

1. Walmart: Size is power

Walmart is a giant, with over 5,300 U.S. stores and 5,200 international locations. Its store base spans from grocery stores to supercenters to warehouse clubs. It has a massive distribution infrastructure to support this network.

All of this helps it attain low prices on goods from its suppliers, which, in turn, allows it to offer lower prices than the competition to its customers, which keeps them coming back again and again. Scale and low prices are, basically, the secret sauce at this retailer, which built an industry-leading position that nobody seems capable of matching.

Shareholders benefited, as well, with the company increasing its dividend annually for an impressive 49 consecutive years. That makes it a Dividend Aristocrat, though it is on the verge of becoming a Dividend King.

Yes, inflation is high today, and a recession would likely be a headwind, but given the strength of the business model, history suggests that buying this stock when others are fearful could turn out to be a good long-term move. The dividend yield today is a somewhat miserly 1.5%, but if a downturn pushed that up into the 2% range, long-term investors will want to take a closer look.

2. Procter & Gamble: Focused on being a better partner

Consumer staples giant Procter & Gamble is a key partner for Walmart, which is basically the company's goal. It achieves this by virtue of its size (it has a $350 billion market cap), which gives it the heft to support a powerful distribution system, hefty research spending, and aggressive marketing efforts. All of these things help to draw customers into stores and expand market categories. 

Although Procter & Gamble's business has been through tough times, it managed through them in a strong fashion. Notably, the dividend increased annually for over six decades, which makes it a Dividend King. The dividend yield is roughly 2.4% today.

The company hiked prices in the face of rapid inflation and achieved notable success in the effort, as consumers largely accepted the price hikes in stride. Although that trend may not last, it still shows just how strong the company's brand portfolio is. And that, in turn, shows why retailers want to work with Procter & Gamble.

There's no reason to think this big-picture view of things will change. So if the stock sells off along with the market and pushes the yield up around the 3% space, long-term investors might want to jump in.

3. Chipotle: Still in growth mode

The last name here, Chipotle Mexican Grill, is a harder one to discuss because the stock is up 450% over the past decade. It also doesn't pay a dividend. That's because the restaurant's cash continues to be put toward expanding its store base.

In fact, the company just recently announced the opening of its 3,100th restaurant. That's a tiny number compared to an industry giant like McDonald's, which has nearly 40,000 locations in 100 countries. However, even if Chipotle only achieved a fraction of that number, it would still have massive growth opportunities ahead.

Investors clearly recognize the potential. And the fact that Chipotle managed to increase comparable-store sales by a hefty 7.6% in the third quarter, despite increasing prices to fight inflation, shows that customers really like this restaurant concept.

The stock is about 20% off its 2021 highs, but it has seen bigger drawdowns, notably during the pandemic-led bear market in 2020. Another big drop like that one, when it fell more than 40%, could be a worthwhile entry point for long-term growth investors.

Buy the best during the worst times

When Wall Street turns negative, it often ends up selling indiscriminately, pushing even the best companies down to attractive levels. Long-term investors should prepare ahead of time, with a list of names that they want to own. That way, when stocks like Walmart, Procter & Gamble, and Chipotle go on sale, you can have the courage to buck the trend and buy.