def make_random_access(iter):
    """
    Return a list or tuple containing the elements of iter.
    If iter is already a list or tuple, it returns iter.
    """
    if isinstance(iter, list) or isinstance(iter, tuple):
        return iter
    return list(iter)