There are times you mess up the committed code and realize it’s not working. So instead of pushing it to the master repository, you want to go back to the previous commit, change the errors, and commit correct version. This happens quite a lot! The key here is that you committed the code but didn’t push it yet. Sometimes the fastest way to learn is to watch! This is probably one of the best video tutorials on the subject.