Create maxSubstring