It took a while, but Apple (AAPL -1.22%) stock is finally back.

AAPL Chart

AAPL data by YCharts

Less than two years ago, Apple stock set an all-time high at just a few dollars above $700, which, after the 7-to-1 stock split, translates to about $100. More specifically, Apple's post-split intraday split-adjusted all-time high was $100.72. On Tuesday, however, Apple's intraday high was just cents away from this all-time high and the stock reached new heights on Wednesday. Once you factor in the dividends Apple has paid out since the company crossed a post-split $100 the first time, it's certainly fair to say that Apple investors who have held during this period have recouped their losses fully.

Looking back at this rollercoaster ride, there are several excellent lessons for investors.

1. Shares can grow faster than market capitalization.
In other words, investors can be rewarded even when the total value of the underlying business doesn't grow. How is this possible? Share repurchases.

Case in point: When Apple hit post-split levels just over $100 the first time, its market capitalization was about $658 billion. This time, however, Apple's market capitalization is just $602 billion -- more than $50 billion lower. How'd this happen? Apple has been aggressively spending on share purchases.

AAPL Shares Outstanding Chart

AAPL Shares Outstanding data by YCharts

When shares can be repurchased at reasonable levels (or better yet, bargain levels), aggressive share repurchase programs like Apple's can create significant shareholder value.

2. Volatility is an investor's best friend.
When Apple stock plummeted to levels around a post-split $60 in 2013, it was clear that Apple stock was cheap. Sure, Apple's gross profit margins were suffering and revenue growth rates were slowing. But the market overreacted far too pessimistically, sending the stock to levels where Apple was trading at a price-to-earnings ratio around 10 for several months in 2013 -- even after Apple doubled its share repurchase program to $100 billion.

AAPL PE Ratio (TTM) Chart

AAPL P/E Ratio (TTM) data by YCharts

Of course, it's not always easy to pull the trigger on a stock when the market is screaming, "sell!" But for those who stirred up the courage to buy shares around a post-split $60, the reward has certainly been sweet.

Long-term investors should keep an eye out of opportunities like this. Benjamin Graham, known as the mentor to Warren Buffett and the "father" of value investing, best explained how to use volatility as a tool in his classic book, The Intelligent Investor

Basically, price fluctuations have only one significant meaning for the true investor. They provide him with an opportunity to buy wisely when prices fall sharply and to sell wisely when they advance a great deal. At other times he will do better if he forgets about the stock market and pays attention to his dividend returns and to the operating results of his companies.

3. Buying-and-holding Apple has worked out exceptionally well.
Despite all the doom and gloom headlines for Apple stock in recent years and the unfortunate loss of Steve Jobs in October 2011, Apple has turned out to be an incredible investment for the buy-and-hold investor.

AAPL Chart

AAPL data by YCharts

For long-term investors with a handful of excellent enduring companies in there portfolio, sometimes it is best to simply sit back, relax, and ignore all the volatility in the near-term.