To learn the harsh realities of life the hard way.
Literally: to learn the price of flour and lentils