Added some code samples for memoizing