Function: REPLACE-WITH-MIN

Source

(defun replace-with-min (node tree)
  (let ((min-node (find-min-node (right node))))
    (setf (key node) (key min-node)
	  (value node) (value min-node)
	  (right node) (delete-from-node (right node)
					 (key min-node) tree))
    node))
Source Context