To say that 2022 has been a rough year in the stock market would be a drastic understatement for many people. All major indexes and many blue chip stocks have seen their stock price plummet this year. However, all isn't bad. Tough times like these can be hard to stomach, but they can also be a time to learn some lessons that are hard to learn without actually experiencing them firsthand.

Here are three investing lessons from 2022 that should stick with you forever.

Bear markets are inevitable

After a stock market crash in early 2020 during the beginning stages of the COVID-19 pandemic, the stock market went on an unprecedented bull run in a short span of time. The S&P 500 (^GSPC -0.46%), which is used as a gauge for the stock market's overall performance, had more than doubled by early November 2021 from its March 2020 lows. For perspective, before the crash beginning in mid-February 2020, it had taken the S&P close to 6.5 years to double in value.

The S&P 500, as we know it now, was formed in 1957, and since then, it has had negative returns in 15 of those years -- almost a quarter of the time. Below are some negative years for the S&P 500 since 1980 and its growth since then (excluding 2022):

YEAR DECLINE PERCENTAGE GROWTH SINCE
2018 -4.4% 55%
2008 -37% 342%
2002 -22.1% 324%
1990 -3.1% 1,072%
1981 -4.9% 3,114%

Data source: S&P 500 historical data / growth rounded to the nearest whole percentage.

History shows that neither bull markets can't last forever, and bear markets are inevitable and a necessary evil. 2022 will likely be only the second year the S&P 500 has had a negative year since the financial crisis (Great Recession) of 2008 -- a humbling reminder that it can't be all good all the time in the stock market even if things work out well for long-term investors.

There's opportunity in the chaos

Once you come to terms with bear markets being inevitable, the sooner you can begin seeing the opportunities in the chaos and using them to your advantage. In particular, down-market periods can be a chance to grab great stocks at a discount and possibly lower your cost basis.

Your cost basis is the average price you've paid per share of a particular stock. For example, if you bought 20 shares of a stock at $200 per share, your average cost basis would be $200. If you bought 20 more shares at $100 each, your average cost basis would be $150. If the price increased to $300 and you bought 20 more, your average cost basis would be at $200 again.

Times when prices are dropping can be an opportune time to lower your cost basis, particularly if you've been buying shares during the past bull market. Lowering your cost basis is ideal because it ultimately determines how much you gain (or lose) when you sell shares in the future. Two people can sell the same number of shares at the same price, but the one with the lower cost basis will profit more.

There's no guessing how stock prices will move

One of the best things you can do as an investor is remain consistent through the good, the bad, and the ugly in the stock market. This is fairly easy to do when it's a bull market, and your investments are rising. It's much harder to remain consistent during down periods when prices are consistently falling. After all, it makes sense to hold off investing until prices reach their bottom, right? 

In theory, yes, that makes sense; no need to buy something today that you can get cheaper later on. The problem is that the stock market doesn't operate that logically, and trying to guess when stocks will bottom out is exactly that: a guess. Nobody can predict the stock market's short-term movements. You can use metrics and other factors to make an educated guess, but there's no way of knowing for sure.

Trying to time the market is a fool's game and all but impossible to do consistently over the long term. Investors can save themselves a headache (and likely money) by instead using a strategy like dollar-cost averaging. Dollar-cost averaging involves investing a fixed amount at set intervals regardless of stock prices. By using dollar-cost averaging, investors lessen the urge to try to time the market because the investing schedule is already set.

You may make investments when prices are high; you may make them when they're low. The most important thing is that you remove some of the emotions involved and trust that it'll even out over time.