XYZ Interview Question

Longest substring in a string with duplicate characters.