Created
April 14, 2022 23:07
-
-
Save halilgezer/6f5e0beeab37d989bb8f42f48866b5bb to your computer and use it in GitHub Desktop.
Binary Search Tree Project
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[7, 5, 1, 8, 3, 6, 0, 9, 4, 2] Show the given arrays Binary-Search-Tree steps. | |
Step 1 : | |
The root is 7 | |
7 | |
Step 2 : | |
The root is 7 and 5 stands left of the 7 | |
7 | |
5 | |
Step 3 : | |
1 stands left of the 5 | |
7 | |
5 | |
1 | |
Step 4 : | |
8 stands right of the 7 | |
7 | |
5 8 | |
1 | |
Step 5 : | |
3 stands left of the 5 and right of the 1 | |
7 | |
5 8 | |
3 | |
1 | |
Step 6 : | |
6 stands left of the 7 and right of the 5 | |
7 | |
6 8 | |
5 | |
3 | |
1 | |
Step 7 : | |
0 stands left of the 1 | |
7 | |
6 8 | |
5 | |
3 | |
1 | |
0 | |
Step 8 : | |
9 stands right of the 8 | |
7 | |
6 8 | |
5 9 | |
3 | |
1 | |
0 | |
Step 9 : | |
4 stands left of the 5 and right of the 3 | |
7 | |
6 8 | |
5 9 | |
4 | |
3 | |
1 | |
0 | |
Step 10 : | |
2 stands left of the 3 and right of the 1 | |
7 | |
6 8 | |
5 9 | |
4 | |
3 | |
2 | |
1 | |
0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment