Inorder tree traversal: Which definition is correct?

前端 未结 14 1346
轮回少年
轮回少年 2020-12-24 03:42

I have the following text from an academic course I took a while ago about inorder traversal (they also call it pancaking) of a binary tree (not BST):

14条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-24 04:17

    The proper traversal would be: as far left as possible with leaf nodes (not root nodes)

    Left Root Right

    A B NULL

    C D E

    Null F G

    H I NULL

    F is root or left, i am not sure

提交回复
热议问题