Minimum Length Substrings Leetcode Python Coding