# Constructing a binary tree from its traversals

Keshan Pillay

Greenhorn

Posts: 29

posted 7 years ago

Firstly, thanks to everyone for answering my previous topics, my assignment is going really well. I'm now on part 2, and I need to construct a binary tree from its post-order and in-order traversals. The sample traversals given were:

Inorder traversal: ADHGKLMRUVTW

Postorder traversal: AHDLKGUVRWTM

Can someone please help me with the algorithm to complete this process?

Many thanks,

Yoonsi

Inorder traversal: ADHGKLMRUVTW

Postorder traversal: AHDLKGUVRWTM

Can someone please help me with the algorithm to complete this process?

Many thanks,

Yoonsi

Satya Maheshwari

Ranch Hand

Posts: 368

Keshan Pillay

Greenhorn

Posts: 29