still in single class format, refactored for readability, better naming conventions, better use of instance/local variables, and privacy