test
implemented memoization for p114, it's fast now!