Implemented some of the problems