Jim Cramer says stocks are caught between the forces of inflation and deflation, and investors need to find companies that can adapt.

The stock market is caught in a race between inflation and deflation, Jim Cramer told his Mad Money viewers Tuesday. And while inflation got head start, the forces of deflation are starting to take hold, but they come with a hefty price.

If you listened to the Colgate-Palmolive  (CL) – Get Colgate-Palmolive Company Report conference call, then you know already know the company sees input costs moderating in the back half of the year. Toolmaker Stanley Black & Decker  (SWK) – Get Stanley Black & Decker, Inc. Report told investors that it expects semiconductors to be more readily available in the second half. These two companies may be outliers at the moment, but they prove that the war on inflation can be won, at least by some.

Over on Action Alerts PLUS, co-portfolio managers Bob Lang and Chris Versace are taking a close look at UPS  (UPS) – Get United Parcel Service, Inc. Class B Report, after the company delivered an upbeat outlook for 2022 and increased its dividend. Get in on the conversation and hear what they’re telling their investment club member at Action Alerts PLUS.

But then there’s the rest of the economy, where manmade rules and regulations keep inflation raging. Labor unions are standing in the way of increased port efficiency, truck drivers aren’t permitted to drive longer hours, food packers can’t run processing lines 24/7 to meet demand and if you want to build a new pipeline to ease natural gas prices, forget about it.

All of these are problems that could easily be solved, Cramer said, but we have a chaotic, dysfunctional system of rules here in America. These rules make our world cleaner and safer, but they come at the cost of preventing companies from quickly adapting to changing conditions. They affect inflation is a seriously negative way, he said, and that’s why it’s taking so long to get our supply chains under control.

Get more trading strategies and investing insights from the contributors on Real Money.

The hope is that companies will bring their manufacturing back to the U.S., but Cramer was doubtful, as the cost of our cleaner, safer world will have to be passed onto the consumer, which no one seems to want.

To sign up for TheStreet’s free Daily Booyah! newsletter with all of the latest articles and videos please click here.