Generate All Substrings Of A String Using Python