Just doing the math, it made sense to Cramer. Selling 10 million barrels a day at $50 apiece is more than selling 11 million barrels at $45. It's also better than selling 11 million at the $40 price where oil might have otherwise headed.

"Going into the meeting, the Saudis upped their production to about 11 million barrels a day, from 10 million, so they are simply going back to where they were last year," the " Mad Money " host said.

The stock market gobbled up that short squeeze on Wednesday, as crude surged 9.3 percent on the news that the Organization of the Petroleum Exporting Countries finally reached an agreement to limit oil production for the first time in eight years.

OPEC may have just "engineered the short squeeze of a lifetime," Jim Cramer said Wednesday.

Smart money got played and they got it wrong. The true believers? They got it right.

Khalid Al-Falih, Saudi Arabia's energy and industry minister, speaks to a member of his delegation ahead of the 171st Organization of Petroleum Exporting Countries (OPEC) meeting in Vienna, Austria, on Wednesday, Nov. 30, 2016.

The OPEC agreement stipulated a cut in production by 1.2 million barrels a day, from the current 33.6 million barrels produced. Saudi Arabia accounted for the largest chunk of that, by agreeing to cut 486,000 barrels per day. OPEC is also seeking a cut of 600,000 barrels per day from non-OPEC producers, and Russia also agreed to temporarily reduce production by approximately 300,000 barrels per day.

Meanwhile, it was just last week that many on Wall Street thought there would be no OPEC deal. Rumors were that no countries would agree to cutbacks, and the only hope was for a freeze at high levels.

This caused the price of oil to dive to the low $40s. Thus, many commodity traders made a bet that there would be no deal, and the price of oil would fall further.

So when OPEC agreed to production cuts, the commodity traders scrambled to cover those short positions.

"It's pretty much a no-brainer because if the other OPEC countries can't physically pump more than they already are, then the algebra works and oil stays higher for now," Cramer said.

Cramer also explained the massive moves seen in domestic oil companies with exposure to the Permian Basin and the area in Oklahoma known as SCOOP. Those companies have found innovative ways to make money at half the current price of crude, Cramer said.

Hence, EOG, Pioneer and Cimarex have all made big investments and acquisitions in the best part of Texas when oil was down, and now they are prepared to step in and make money when oil falls below $50.

"Smart money got played and they got it wrong. The true believers? They got it right," Cramer said.