added file PrefixMemo which is a step toward memoization based on list prefix