Having a backup plan does not only happen in school. It can also happen at work.
When I first started working for a doctor's office, it just so happened that the area would always be hit by a thunderstorm that would cause power surge or power fluctuations or worse, even a blackout.
Having a backup plan would always prove handy in cases of emergency.
The same thing in class. If the PowerPoint machine does not work, it is good to have a backup plan with making the students follow your lecture by having their textbook open and highlight or write notes as we go along.
Sometimes we also will be transferred to a lecture room because there is an immediate need for the computer room. I explain to the students that we have to transfer to the lecture room and since we have no access with the computers, we will do the lectures instead and catch up tomorrow with the computer work.
I always assure the students not to worry we will have time to catch up.
With regards coding practices, I always have coding exercises available for the students to practice on if they are not clear with some coding guidelins.
By having a backup plan, the student will not even notice that there was a chang of plan and that it is business as usual.