The three rules of Ruby Quiz: 1. Please do not post any solutions or spoiler discussion for this quiz until 48 hours have passed from the time on this message. 2. Support Ruby Quiz by submitting ideas as often as you can: http://www.rubyquiz.com/ 3. Enjoy! Suggestion: A [QUIZ] in the subject of emails about the problem helps everyone on Ruby Talk follow the discussion. Please reply to the original quiz message, if you can. -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= A famous set of computer problems involve verbal arithmetic. In these problems, you are given equations of words like: send + more ------ money or: forty ten + ten ------- sixty The goal is to find a single digit for each letter that makes the equation true. Normal rules of number construction apply, so the first digit of a multi-digit number should be nonzero and each letter represents a different digit. This week's quiz is to build a program that reads in equations and outputs solutions. You can decide how complex of an equation you want to support, with the examples above being the minimum implementation. Here's a solution you can test against: $ ruby verbal_arithmetic.rb 'send+more=money' s: 9 e: 5 n: 6 d: 7 m: 1 o: 0 r: 8 y: 2