Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef BST_H
- #define BST_H
- #include <stdio.h>
- #include <stdlib.h>
- typedef int Data;
- typedef struct BinarySearchTree
- {
- struct BinarySearchTree * Left;
- struct BinarySearchTree * Right;
- Data data;
- }BSTNode;
- BSTNode * BST_CreateNode(Data data);
- BSTNode * BST_RemoveNode(BSTNode * Tree, BSTNode * Parent, Data data);
- BSTNode * BST_SearchNode(BSTNode * Tree, Data data);
- BSTNode * BST_SearchMinNode(BSTNode * Tree);
- void BST_InsertNode(BSTNode * Tree, BSTNode * Child);
- void BST_DestroyNode(BSTNode * Node);
- void BST_DestroyTree(BSTNode * Tree);
- void BST_InorderPrintTree(BSTNode * Tree);
- #endif
Add Comment
Please, Sign In to add comment