Implemented the rest of the code for the project