Additonal Trees
Priority Queues
- queue - "type-cheat" and sort it
- ordered list queue
- arrays of queues
- modify queue insert "by searching" for placement
- partially ordered tree - "heap"
priority of node is greater than that of its children (assumes low is good)
General Tree Node Implementations
General Tree Traversal
InTrav(Ptr P)
{
if (P == NULL)
return;
else
{
InTrav(P -> Child);
Visit(P);
InTrav(P -> Sib);
return;
}
}
How to house these in a data structure to distinguish these
words quickly?
THE
THEN
THIN
TIN
SIN
SING
Each node has an array with 26 locations representing each
letter.
Height of tree = length of longest word.
Return to CIS 350 Index Page