I know inorder traversal works like this:
But what if we have an algorithm that does the following
Would such a tree traversal be consdered inorder as well?
I was wondering the same thing for some time.
I would say, it can be called inorder traversal also. The result would be reverse sorted array instead of the sorting that would come up with left-root-right.
But the definitions are strict on saying left-root-right.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With