SubStringDivisibility problem 43 Python