What happened

Shares of 2U (TWOU 4.17%) exploded higher on Friday morning after the online learning company reported a modest earnings beat in its fiscal Q4 2022 results last night. Analysts had expected 2U to earn only $0.21 per share for the quarter, and 2U topped that forecast with an adjusted profit of $0.23 per share.    

As of 11 a.m. ET, 2U stock is up 24.8%.

So what

And yet, not all the news was good. While 2U reported a profit for the quarter on a non-GAAP (adjusted) basis, when calculated according to generally accepted accounting principles (GAAP), 2U actually lost $0.15 per share. (On the plus side, this was significantly less money than 2U lost in Q4 2021.)  

Sales for the final quarter of last year declined 3% year over year to $236 million as enrollment in the company's non-degree "alternative credential" segment grew, but enrollment in programs that do award degrees shrank.

For all of fiscal 2022, sales fell 2% to $963.1 million, and losses widened 65% to $4.17 per share.

Now what

Despite the year's sizable losses, 2U CEO Christopher Paucek insisted he is "increasingly confident in our platform strategy," and argued 2U is "radically improving our marketing efficiency, and delivering significant EBITDA growth," particularly in non-degree programs, which are expected to turn profitable this year.

If you ask me, that's probably the most positive revelation from last night's results: The fact that the division that is losing money is the one that is shrinking, while the segment that might soon earn money is growing. True, combined, 2U's two businesses are still expected to rack up losses of at least $1.14 per share this year. But if 2U is growing in the right areas and sees a path to profitability in that direction, then that's a reason to be optimistic about this stock over the long term.

The big question for investors is: how long? And how patiently can they wait for profitability to arrive?