steve said over 5 years ago on Ruby Objects and Memoization :
Great Stuff! -Steve

John PRO said about 5 years ago on Ruby Objects and Memoization :
That fibonacci example was a really good example!

Uriel said almost 4 years ago on Ruby Objects and Memoization :
Epic the fibonacci example, thank you.

Jeffrey Soong said about 3 years ago on Ruby Objects and Memoization :
can someone explain why do you need an instance method find to loop and find the record when the looping can be done in the class method? Wouldn't you be able to something like attached below?

class << self
 def find(id)
   return unless id
   new(USERS.find { |user| user[:id] == id })
 end
end

David Kimura PRO said about 3 years ago on Ruby Objects and Memoization :
  You really don't need the instance methods in that example, It can be done at the class level. If I were to go back and redo this episode, I would leave any class level qualifying methods out of instance level methods. 

Rafael Hashimoto said over 1 year ago on Ruby Objects and Memoization :
Wow, I didn't understand why you decidef to use the fibo example at first, but after a while everything made sense. Great example!!



Login to Comment