Exercise 1 for spring 2014 in Introduction to Computer Science.