Non Recursive In-Order Traversal without using stack

A

AD

Hi,

I know it is not exactly a C++ problem but rather concerns algorithm.
But I could not figure out any other group to post this so am posting
here.

I am looking for the algorithm proposed by Morris for inorder traversal
of a Binary Tree without using explicit stack. Searched on net but
could not find many clues.

This was the nearest I could reach:
https://www.cs.tcd.ie/research_groups/fmg/IFMSIG/winter2000/HughGibbonsSlides.pdf

Anybody with a better idea?

thanks & regds
AD
 
A

al pacino

1)you can post this on comp.programming

2)non recursive inorder traversal WITHOUT using
a stack?

is it possible? i dont think so.
 
A

AD

thanx for suggesting where to post this..i should ask it there...

meanwhilie there are many ways to do it without stack like using
threads or using inverted pointers, etc. But these methods require
additional pointers/bits in each node of tree. Morris' algo works on
the very basic implementation of tree.

regds
AD
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top