Source: Apache Corporation.

A lot of oil companies are struggling with the price of crude stubbornly stuck below $50 a barrel. Their struggles are largely due to two factors: They have too much debt and their costs are too high. However, neither is a problem at Apache Corporation (APA -0.72%), which has reduced both substantially over the past year. As a result, the company is poised to thrive even if oil stays in its current range.

Check, please
Over the past year, Apache has repositioned its portfolio to focus its attention on three core areas. It has sold a number of assets, including its deepwater assets in the Gulf of Mexico to Freeport McMoRan (FCX 0.35%), its LNG assets, and a number of its international assets. Those sales brought in $10 billion in cash since the start of last year, which it used to pay down debt. It's reduced net debt by 28% just since the end of the first quarter of this year:

Source: Apache Corporation.

Not only has the company substantially reduced its outstanding debt, but it also has a tremendous amount of liquidity, with $2 billion in cash on its balance sheet to go along with $3.5 billion available on its credit facility. That gives the company ample cash to operate in the currently tough environment.

Now, contrast that with Freeport-McMoRan, which has been burdened by weak oil prices, as well as weakness in its mining operations. Because of this price weakness, Freeport expects to produce only $3.3 million in operating cash flow this year, which isn't nearly enough to cover the company's $6.3 billion in planned capex spending. With more than $20 billion in debt already on the books, and a troubling 3.9 debt-to-EBITDA ratio, the company can't really afford to bridge the gap between cash flow and capex with debt. This situation is forcing Freeport to look for other alternatives, including the potential sale of a stake in its oil and gas business to bring in some much-needed cash.

Making money at $50 oil
Freeport-McMoRan is far from the only company struggling to bridge a growing gap between its cash flow and capex. However, it's a struggle we don't see at Apache. It can easily grow its production by the low single digits even while staying within the cash flow its oil and gas production has generated. In other words, that $2 billion in cash on its balance sheet is a real cushion that the company would need only in an emergency situation. It's an emergency stash that Freeport-McMoRan and many of its other peers would really love to have in the current environment.

That Apache has such strong cash flow is largely a result of the abundant cash flow from the international assets it held onto, in Egypt and the U.K. North Sea, even at a low oil price. Further, its legacy North American assets are low-decline plays, which don't require much capital to maintain production. Also helping the company is that it jettisoned cash-consuming projects, such as the Gulf of Mexico assets it sold to Freeport-McMoRan and its stakes in LNG projects. Because of this strategic shift, the company has a lot of cash flow to reinvest elsewhere, which is primarily going toward drilling North American shale wells that start generating their own cash flow really quickly.

The other important factor here is that the company has captured strong cost reductions, with its North American well costs and G&A cash costs both down 25% year over year, while its lease operating expense per barrel of oil equivalent is down 13% over that same time frame. All of its key plays thus have economic drilling opportunities at sub-$50 oil. This combination of lower capital requirements and strong economic drilling opportunities are the key to Apache's ability to live within its cash flow next year, while still being able to deliver modest production growth even if oil prices remain weak.

Investor takeaway
Apache Corporation has two big competitive advantages over its peers: a strong balance sheet and the ability to grow within its cash flow at the current oil price. Apache therefore won't just survive the downturn, but it's also in a position to thrive even if the price of oil remains around $50 a barrel. That's not something that many of its rivals, including Freeport-McMoRan, can say right now.