def _rotate_round_robin(top, bottom):
    """Performs the round robin rotation (circle) as proposed in
    https://en.wikipedia.org/wiki/Round-robin_tournament#Scheduling_algorithm

    Args:
        top: Teams in the top row, must have the same length as bottom.
        bottom: Teams in the bottom row, must have the same length as top.

    Returns:
        The next tuple (top, bottom) where top and bottom are the newly rotated lists, arguments are left unchanged.
    """
    top_last = top[-1]
    bottom_first = bottom[0]
    top_res = [top[0], bottom_first] + top[1:-1]
    bottom_res = bottom[1:] + [top_last]
    return top_res, bottom_res