Safe Haskell | Safe |
---|
A Module for Binary Trees.
Documentation
A binary tree is either Empty
or consists of a Note
with
at most two direct subtrees.
height :: BTree a -> Integer Source #
The height
of a binary tree is the length of the longest path
from the its root to one of its leafs.
searchTree :: Ord a => [a] -> BTree a Source #
Building a binary search tree from a list.