#ifndef BST_H_ #include #define BST_H_ /* * A node has a value, as well as a left and right child */ struct _Node { uint32_t value; struct _Node* leftChild; struct _Node* rightChild; }; typedef struct _Node* Node; void printTree(Node root); /* * Returns the size of the tree */ uint32_t treeSize(Node n); /* * Create a new node */ Node makeNode(uint32_t num); /* * Insertion of an element into a tree */ int insert(uint32_t num, Node newNode, Node* root); /* * Locating an element in a tree */ int get(uint32_t num, Node root); /* * Removing an element from a tree */ int removeNode(uint32_t num, Node* root); int height(Node root); int heightHelper(Node n); #endif /* BST_H_ */