Implemented first 3 exercises.