> irb(main):012:0> 15 .choose 7 > 6435 > irb(main):013:0> class Integer > irb(main):014:1> memoize :choose > irb(main):015:1> end > [:choose] > irb(main):016:0> 15 .choose 7 > 57 > > Oops! I'm one confused piggy. I haven't looked at it too carefully, but I'd guess that the problem has to do with the fact that nCr is a function of two variables. Maybe Memoize can only handle functions of one variable (in the general case).