Kalepa interview question

Find the longest substring with max 2 distinct characters.