Color calculator written as an exercise/