solutions to the euler problems in ruby