memoize num-pair->key
confirmed memoization is working