Recursive back pocket - memoization

Doez not work :(