The again variable was being called before being instantiated.
Typo corrected on line 24
corrected a for loop, added a return statement around line 20-25
Here I've changed some minor things with this file. Fixed some typos, called proper functions. Fixed a loop. Still need to find a way to sanitize some integer input.