Jump to content

Left-child right-sibling binary tree

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Duplico (talk | contribs) at 20:23, 16 May 2007. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

In computer science, a left child-right sibling binary tree is a method of converting a k-ary tree to a binary tree. The process is not reversible in general without additional information.

To form a binary tree from an arbitrary k-ary tree by this method, the root of the original tree is made the root of the binary tree. Then, starting with the root, each node's leftmost child in the original tree is made its left child in the binary tree, and its nearest sibling to the right in the original tree is made its right child in the binary tree.

If the original tree was sorted, the new tree will be a binary search tree.