def more_than_one_index(s, brackets=2):
    '''
    Search for two sets of [] []
    @param s: string to search
    '''
    start = 0
    brackets_num = 0
    while start != -1 and brackets_num < brackets:
        start = s.find("[", start)
        if start == -1:
            break
        start = s.find("]", start)
        brackets_num += 1
    if start != -1:
        return True
    return False
def more_than_one_index ( s , brackets = 2 ) : start = 0 brackets_num = 0 while start != - 1 and brackets_num < brackets : start = s . find ( "[" , start ) if start == - 1 : break start = s . find ( "]" , start ) brackets_num += 1 if start != - 1 : return True return False
Search for two sets of [] []
    @param s: string to search