# Write a Python program to Exceptional Split in String # Python3 code to demonstrate working of # Exceptional Split in String# Using loop + split()  # initializing stringtest_str = "gfg, is, (best, for), geeks"  # printing original stringprint("The original string is : " + test_str)  # Exceptional Split in String# Using loop + split()temp = ''res = []check = 0for ele in test_str:    if ele == '(':        check += 1    elif ele == ')':        check -= 1    if ele == ', ' and check == 0:        if temp.strip():            res.append(temp)        temp = ''    else:        temp += eleif temp.strip():    res.append(temp)  # printing result print("The string after exceptional split : " + str(res)) 