The question you opened
The snail in the twelve metre well
A snail climbs a 12 metre well: up 3 metres each day, down 2 metres each night.
On which day does the snail reach the top?
Day 10
The snail nets 1 metre a day, so it starts day 10 at 9 metres. It climbs 3, reaches the top, and never slides back.
A snail climbs 3 metres up a 12 metre well each day and slides 2 metres back each night. It gets out on day 10, and the popular answer of day 12 is two days late. The net progress is 1 metre per full day and night, which is where the 12 comes from. That arithmetic is correct for every day except the last one. On the day the snail reaches the top it climbs out, and there is no night to slide back down.
Track it. At the start of day 1 the snail is at 0 and ends the night at 1. Start of day 2 at 1, end of night at 2. The pattern is clear: at the start of day n the snail sits at n minus 1 metres. It needs to start a day at 9 metres or higher, because 9 plus 3 is 12. Starting at 9 metres means n minus 1 equals 9, so n equals 10.
On day 10 it climbs from 9 to 12 and is gone. The general form is worth writing down. With a climb of c, a slide of s and a height of h, the answer is the number of full cycles needed to reach h minus c, plus one final day. Here that is 12 minus 3, which is 9, divided by the net 1, giving 9 days, plus the last day: 10. This shape appears wherever a process repeats until it crosses a finish line.
A battery that charges more than it drains. A debt paid down faster than interest accrues. A queue that shortens by a few people per hour and grows overnight. In every case the last cycle is incomplete, and treating it as a full one overstates the time. The habit is to ask what happens on the final step and whether it is really the same as the others. Usually it is not, and usually that is the entire question.
Technique: Handle the last step separately