26
Views
1
CrossRef citations to date
0
Altmetric
Original Articles

A study of binary tree traversal algorithms and a tag-free threaded representation

&
Pages 171-185 | Received 01 Oct 1985, Published online: 19 Mar 2007
 

Abstract

Starting from a stack-based binary tree traversal algorithm for preorder and/or inorder, we derive an algorithm recently discovered by J. M. Morris which requires neither stack nor tag fields. This algorithm may also be derived from the familiar threaded binary tree traversal algorithm. By demonstrating how searching may proceed in parallel with traversal, we show that the algorithm is “almost read-only”. This leads to a new representation for threaded binary trees requiring no tag fields. We show how to perform the usual operations efficiently for this representation, including strictly read-only traversal. In addition, we analyse the performance of variants of the traversal algorithm for binary trees represented with/without threads and with/without tag fields.

Reprints and Corporate Permissions

Please note: Selecting permissions does not provide access to the full text of the article, please see our help page How do I view content?

To request a reprint or corporate permissions for this article, please click on the relevant link below:

Academic Permissions

Please note: Selecting permissions does not provide access to the full text of the article, please see our help page How do I view content?

Obtain permissions instantly via Rightslink by clicking on the button below:

If you are unable to obtain permissions via Rightslink, please complete and submit this Permissions form. For more information, please visit our Permissions help page.