Assignment 6 check-in and finalized for grading

made the calculation section a function too

I need to comment my includes to know if they are needed or not.