MCPcopy Create free account
hub / github.com/codemistic/Data-Structures-and-Algorithms / main

Function main

CPP/Trees/BinarySearchTree.cpp:50–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

48}
49
50int main()
51{
52 BSTNode* root = NULL;
53 root = Insert(root, 15); //&root
54 root = Insert(root, 10); //&root
55 root = Insert(root, 20); //&root
56 root = Insert(root, 25); //&root
57 root = Insert(root, 8); //&root
58 root = Insert(root, 12); //&root
59
60 int number;
61 cout << "Enter number be searched\n";
62 cin >> number;
63
64 if(Search(root, number) == true)
65 cout << "Found" << endl;
66 else
67 cout << "Not found" << endl;
68}

Callers

nothing calls this directly

Calls 2

InsertFunction · 0.70
SearchFunction · 0.70

Tested by

no test coverage detected