Saifedean explains it better than I can in The Fiat Standard.
But it's basically possible to earn a positive result with a money that apparently loses money by:
- Securing high quality debt (as in, low rates, long terms, little or no collateral needed).
- Running a business that can update its prices with inflation easily.
- Buying real assets that will keep up with inflation.
On a micro scale: an Argentinian taxi driver might earn more money buying a car with an auto loan that actually running the service, because inflation shrinks his debt and makes the car increase in value in nominal terms.