Amazon interview question

Leetcode problem Longest Duplicate Substring