lib/bst.rb
#
# do not insert val if already in the tree!
#
do not insert val if already in the tree!
do not insert val if already in the tree!
def insert(val, root=@root)
      parent, link, found = _search(val, root, root, nil)
      _create_node(val, parent, link) unless found
    end
def insert ( val , root = @root ) parent , link , found = _search ( val , root , root , nil ) _create_node ( val , parent , link ) unless found end
do not insert val if already in the tree!
do not insert val if already in the tree!
#
val
<not_specific>
root
<not_specific>