Oh, how quickly the market forgets.

After a blowout earnings season, the S&P 500 (INDEX: ^GSPC) gave back all its gains for the year, falling 10% in May. Wall Street had expected an underwhelming quarter, but stocks posted earnings well ahead of estimates. Of the 30 Dow Jones Industrial Average (INDEX: ^DJI) components, 26 beat the Street, while two of the remaining four met expectations. Two-thirds of S&P 500 stocks also beat estimates, and profit margins were exceptionally high at 8.58% (compared to a historical average of 6.11%). Despite the tumult in Europe and moderating growth in Asia, corporate profits are still strong.

Based on historical averages, stocks look nearly as cheap as they've been in the last 25 years. The S&P 500 has averaged a P/E of 25 and a median of 21 in that period, and its current trailing multiple of 14.5 is at a low not seen since the late 1980s. Flip it around and the forward P/E looks even better at 12.2.

Of course, stocks don't operate inside a bubble; they're always competing for investments with other financial vehicles. In a recent Gallup poll, Americans said they believed the following would make for the best long-term investment:

  • Gold: 28%
  • Real estate: 20%
  • Stocks: 19%
  • Savings accounts: 19%
  • Bonds: 8%

Sounds like a hung jury. Let's take a look at some of the alternatives and see why the stock market looks like the best bet.

Treasuries, shmeasuries
Treasury yields have sunk to 60-year lows. The benchmark 10-Year T-Note (INDEX: ^TNX) currently yields 1.55%, and has fallen as far as 1.47%. Despite the S&P's credit downgrade last summer, investors still see U.S. Treasuries as the safest place to put their money, as concern about the euro's future only makes the greenback shine brighter. Yields on corporate bonds have also fallen along with treasuries.

Dividend stocks, on the other hand, offer much better returns as payouts continue to rise. The S&P 500 currently sports a dividend yield of 2.16%, and not since 1958 has the index's dividend yield beat treasuries.

Flipping houses ain't what it used to be
Investors seem to have learned their lesson from the housing boom and bust of the last decade. A house is a place to call home, not a get-rich-quick scheme. Even with mortgage rates at all-time lows, the housing market is still searching for bottom. Nearly four years after the bubble popped, there's still a glut of foreclosed homes on the market that ensures that national home prices won't be spiking anytime soon. Don't get me wrong: A smart real estate investment can certainly deliver huge returns, especially if it's in a developing or gentrifying area, and rental property can pay off as well, but with so many states awash in speculative housing, real estate is not going to beat equities.

Sorry, you missed the gold rush by about two centuries
I've never understood the gold obsession. Sure, I like shiny rocks as much as the next guy, but as an investment it never really made sense to me. To be fair, as the SPDR Gold Shares ETF (AMEX: GLD) indicates, the precious metal has crushed the market over the last decade, up about five times while stocks are down since the tech boom. But without something meaningful like earnings underpinning those gains, I see little reason to believe that gold prices couldn't collapse just as easily. I get that investors see it as a timeless fallback currency, but as my colleague Alex Dumortier points out, gold prices are no longer tracking with market risk as one might expect. The precious metal is down about 15% from its peak in September, while treasuries and other "safe" assets continue to rise. With scant practical or inherent value, gold is only worth as much as the next investor is willing to pay for it -- just an adult version of trading baseball cards. A stock or a bond, on the other hand, represents a claim on assets or future earnings, while fixed assets and most commodities serve a purpose in and of themselves.

In essence, investing in gold seems like a bet that either time travel will be invented in our lifetime (I'll leave the possibilities up to your imagination) or that all the treasuries in the world will run out of ink at exactly the same moment. I'm totally comfortable taking the other side of that bet.

Show me the money
In the aftermath of the financial crisis, corporations trimmed the fat, boosted productivity, and improved efficiency, lifting profit margins to record highs. Those improvements won't be undone, meaning every additional dollar in revenue will be even more valuable to shareholders as more of it goes to the bottom line.

U.S. corporations are also hoarding record levels of cash, with non-financial companies holding around $2 trillion. By comparison, the market value of all publicly traded companies in the world is estimated to be $50 trillion. All that cash in the bank, which belongs to shareholders, means that the multiples you see are artificially inflated. Apple (Nasdaq: AAPL), for instance, trades at a P/E of 13.7, but with over $100 billion in cash and investments, its P/E is more like 11 once you back out the cash pile.

Investors may keep worrying about high unemployment at home, the billowing European debt crisis, and China's growth slowing, but there are still plenty of opportunities in the stock market. And it's clear from the numbers above that corporations have enough cash to make it through a year's worth of rainy days.

Don't forget dessert
Dividend stocks can be some of the best bets in today's market climate. With bond yields at historic lows, investing in defensive stocks can give you a quarterly chunk of cash to help build your portfolio while protecting you from severe stock market crashes. Our experts at the Fool have found a group of blue chip dividend-payers that you can count on to deliver returns over the long haul. Find out what these top-notch investments are in the Fool's special free report: "Secure Your Future With 9 Rock-Solid Dividend Stocks." Get your free copy right now. All you have to do is click right here.