Added more functions and made sure all specs passes