What could be wrong if your 2002 alero's heater air is warm-- then goes cold--then the thermostat goes up and then the heat is warm again and the thermostat goes back down?

Souns like a head gasket to me.