Changed version to give to students to use clearer variable names, added comments, etc.