Ruby Monk and ProjectEuler problem solutions