import re


def search_re_in_list(out, l):
    """ Search the regular expression 'l' in each line of
        the given string list 'out' and return the line's index
        when successful.
    """
    for idx, o in enumerate(out):
        m = re.search(l, o)
        if m:
            return idx

    return None