9 lines
350 B
Plaintext
9 lines
350 B
Plaintext
Inorder of a binary search tree is sorted
|
|
=========================================
|
|
|
|
inserted in this order : [50, 30, 70, 20, 40, 60, 80]
|
|
tree : 50(30(20,40),70(60,80))
|
|
preorder : [50, 30, 20, 40, 70, 60, 80]
|
|
inorder : [20, 30, 40, 50, 60, 70, 80]
|
|
postorder : [20, 40, 30, 60, 80, 70, 50]
|