We're looking for the best bargains in defense stocks, and comparing the alternatives two by two. Today's contest: Huntington Ingalls stock versus L-3 Communications. Image source: Getty Images.

Warships or wi-fi? Which makes for the better investment?

It's a high-tech world out there, in the defense industry as everywhere else. Today we're going to take one of the defense industry's high-tech stars -- electronics specialist L-3 Communications (NYSE:LLL), and pit it against Huntington Ingalls (NYSE:HII), one of the nation's biggest builders of military warships.

Which stock makes for a better investment? Let's find out.

L-3 Communications

L-3 Communications is up first. This $11.5 billion company does business in three main spheres. Electronic systems is L-3's biggest business, and also its most profitable. Supplying electronic components to the military and civilian industry brings in $4.4 billion in revenue annually for L-3 Communications and earns it an operating profit margin of 11.1%.

Aerospace systems is slightly smaller at $4.2 billion, and much less profitable, with a margin of only 4.9%. Bringing up the rear is the company's namesake division, communications systems, with an annual revenue stream of $2.1 billion and an annual profit margin of 9.4%.

Averaged all together, L-3's three big businesses produce about $10.5 billion in annual revenue, and earn an operating profit margin of 8.5% thereon.

Valuation-wise, L-3 Communications stock sells for 1.1 times sales -- not too far above the norm for defense contractors historically. Because of multiple "one-time" charges taken in recent quarters, L-3 is currently not profitable. The company does have decent free cash flow, though, and generated $852 million in cash profits over the past 12 months (according to data from S&P Global Market Intelligence). Valued on that metric, the stock sells for about 13.5 times free cash flow.

Again, that doesn't seem too expensive. But relative to the stock's 8.2% expected long-term growth rate, and its relatively modest 1.9% dividend yield (total expected return -- 10.1%), 13.5 times free cash flow may be a bit too much to pay (especially in light of the stock's $3.1 billion net debt load).

Huntington Ingalls

Smaller, faster-moving Huntington Ingalls, in contrast, is a warhorse of an entirely different color. Specializing in the production of warships, Huntington's business is much less diversified than L-3's, which might make you worry that it's a less attractive investment.

It isn't.

In fact, with $7.2 billion in trailing revenues, Huntington Ingalls currently boasts net profits of $453 million annualized, versus L-3's trailing net loss. Farther up the income statement, at the operating profit level, Huntington is also more profitable than L-3, boasting an 11% operating profit margin on its sales.

Valuation-wise, Huntington stock carries an $8 billion market capitalization, valuing the stock at 1.1 times sales. (That looks similar to L-3's valuation, but Huntington carries a far lighter debt load than does L-3 -- less than $500 million after backing out cash). Huntington Ingalls stock sells for 17.7 times earnings, but only 12 times its copious free cash flow of $667 million.

Best of all, analysts who follow these stocks see Huntington Ingalls growing its earnings at better than 27% annually over the next five years. That's an aggressive target. But if Huntington should somehow achieve it, that would mean the stock sells for a PEG ratio of just 0.6, and a price-to-free cash flow-to-growth ratio of just 0.4.

In other words: Cheap!

Cheap, yes. But realistic?

Is it realistic to expect Huntington Ingalls to grow earnings at 27% or better over the next five years? Honestly, I have my doubts. The U.S. government isn't exactly awash in dollars to spend on new warships these days, which could constrain revenue growth. Meanwhile, Huntington management has cautioned investors that the 11% operating profit margins it's enjoying today are unlikely to last.

"9% to 10%" margins, says Huntington Ingalls CEO Michael Petterson, are probably more realistic over the long term. And that that means it's going to take some serious revenue growth going forward just to maintain Huntington Ingalls' profits, much less grow them at 27%.

All of that being said, we go to valuation with the facts we have today, not the facts we'd like to know about the future. Based on the numbers we know -- trailing sales, earnings, and free cash flow -- and weighing the long-term growth projections analysts assure us we can rely upon, there's really no contest, here. Based on what we know right now, Huntington Ingalls is clearly a cheaper stock than L-3 Communications; it's carrying less debt, and it's also likely to grow faster.

That's three strikes against L-3 Communications and in favor of Huntington Ingall, and it makes Huntington Ingalls stock the better buy.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.