[LongestSubStr] O(nlogn) DP+map