Aquarium controller with a debounce on the temperature sensor

So if I understand correctly, I would code it as:

if the actual temperature < then 76, write high until the temp is reached at 77 for example. Although the setpoint maybe selected at 76, using your method it would actual then take the temperature up to 77. It doesn't matter if the temp read goes to 75.99 for a second, it will turn on until it reached the upper set point every time.

The way I am thinking that should in fact keep it from bouncing.