Finished the programming part of the assignment