This a simple BST implemented in Golang. It currently implements the following methods:
- Insert() - insert a single integer
- Remove() - remove node with specified value
- Search() - search the BST for a value
- Height() - get the height of the tree
- Count() - get the number of nodes in the tree
- Min()/Max() - the the minimum/maximum value in the tree
- InOrder() - perform an inorder traversal and return a slice of ints
Run tests using go test
to validate changes.
Disclaimer: I am new to using Go, so please feel free to offer feedback.