Code:
root node { array of child nodes };
child node type 1 { letter, state, union { array of child nodes, definition } };
Or also what I was thinking in a more C like sense
Code:
root node { pointer to array of child nodes }
child node type 1 { letter, pointer to array of child nodes };
child node type 2 { letter, pointer to array of child nodes = 0, definition };
And once the app detects that the array of child nodes is NULL, it changes how it looks at the type, and see's that it will have a definition.
>> Not good for every situation as the keys would have to be strings. To me it apears one of the only draw backs are if the key is long in length, but that is totaly up to the user so it shouldn't be much of a problem.
What else would the key be if you're looking through a dictionary? You could even be going through the tree as the user types, I can't see why the length would be a drawback.