Solution to the Guidewire competition round 1 Amusing Sums question.