Added a memoization technique

In reference to http://thereq.com/q/99/ruby-software-interview-question/memoization-techniques