Refactoring to prepare for 1.4
Solve exercise 4 from set 1