Re: Inorder Traversal of B-Tree
- From: annamalai <annamalai.gurusami@xxxxxxxxx>
- Date: Tue, 29 Jan 2008 06:36:58 -0800 (PST)
On Jan 28, 11:37 pm, Logan Shaw <lshaw-use...@xxxxxxxxxxxxx> wrote:
(snip)
So a correct in-order traversal of a B-tree will return the keys in
order, and an implementation of a correct in-order traversal will
be built upon the properties of a B-tree that allow it to keep the
keys in order.
Thank you for that information. So I can verify whether my in-order
traversal of a B-Tree is correct by looking at the order in which the
keys are being visited. This basically will involve visiting a node N
times where N is the number of keys in the node.
But what about pre-order and post-order traversal? Will this also
apply to them? Will I visit the node N times in them too? Or will I
visit the node only once (and so visit all keys in that node one after
another). For example, at http://en.wikipedia.org/wiki/Tree_traversal,
the first two lines say that each node is visited exactly once. That
is not very correct, right?
(begin-quote)
In computer science, tree-traversal refers to the process of visiting
each node in a tree data structure, exactly once, in a systematic way.
(end-quote)
Thank you.
Rgds,
anna
- Logan
.
- References:
- Inorder Traversal of B-Tree
- From: annamalai
- Re: Inorder Traversal of B-Tree
- From: user923005
- Re: Inorder Traversal of B-Tree
- From: annamalai
- Re: Inorder Traversal of B-Tree
- From: Logan Shaw
- Inorder Traversal of B-Tree
- Prev by Date: Re: Crossword project.
- Next by Date: Re: crossword project works
- Previous by thread: Re: Inorder Traversal of B-Tree
- Next by thread: sending to hConsoleInput for child process (Win32/C++)
- Index(es):
Relevant Pages
|