Lesson 04 version

Much improved, using defined error conditions and a switch() block