DP on Treesstringoptimization

Longest repeating and non-overlapping substring

Given a string, find the length of the longest substring that occurs at least twice within it, where the two occurrences do not overlap each other in position.

Note. Listed under DP on Trees in the course's source list, but the recurrence compares two positions within one string, making it a stringPair2d problem rather than a tree DP.

Do this lesson first: longest common subsequence

The full breakdown and animated table for this problem are still being written. In the meantime, run the four questions on it yourself — that is the whole exercise.