Fork me on GitHub

The solution for subword $i..j$ is stored at $M[i + (j\cdot(j+1)) \div 2]$ where $M$ is a one-dimensional array of size $(|w|+1)\cdot(|w|+2) / 2$. This completely eliminates the space loss of the naive strategy.

Delay: (try 0!)
(note: doesn't affect a running animation)
Word length: