def join_list_pretty(ls):
    """
    Join a list in a human readable way.
    An empty list returns the empty string.
    A list with a single element returns the only element of the list converted to a string.
    A list with two elements returns a string in the format "x and y".
    A list with three or more elements returns a string in the format "x, y, and z"

    Parameters
    ----------
    ls: list
        The list to join
    """
    if len(ls) == 0:
        return ""
    elif len(ls) == 1:
        return str(ls[0])
    elif len(ls) == 2:
        return str(ls[0]) + " and " + str(ls[1])
    else:
        return ", ".join((str(x) for x in ls[:-1])) + ", and " + str(ls[-1])