def generate_name(length=15, not_in=None):
    """
    Generates a random string of lowercase letters with the given length.

    Parameters:
        length (int): Length of the string to output.
        not_in (list): Only return a string not in the given iterator.

    Returns:
        str: A new name thats not in the given list.
    """
    value = ''.join(random.choice(string.ascii_lowercase) for i in range(length))

    while (not_in is not None) and (value in not_in):
        value = ''.join(random.choice(string.ascii_lowercase) for i in range(length))

    return value
def generate_name ( length = 15 , not_in = None ) : value = '' . join ( random . choice ( string . ascii_lowercase ) for i in range ( length ) ) while ( not_in is not None ) and ( value in not_in ) : value = '' . join ( random . choice ( string . ascii_lowercase ) for i in range ( length ) ) return value
Generates a random string of lowercase letters with the given length.

    Parameters:
        length (int): Length of the string to output.
        not_in (list): Only return a string not in the given iterator.

    Returns:
        str: A new name thats not in the given list.