Removes the minimum element from the tree

    Returns:
        tuple: new_root, first_node

    O(log(n)) = O(height(root))

def avl_split_first(root):
    """
    Removes the minimum element from the tree

    Returns:
        tuple: new_root, first_node

    O(log(n)) = O(height(root))
    """
    if root is None:
        raise IndexError('Empty tree has no maximum element')
    root, left, right = avl_release_kids(root)
    if left is None:
        new_root, first_node = right, root
    else:
        new_left, first_node = avl_split_first(left)
        new_root = avl_join(new_left, right, root)
    return (new_root, first_node)