Arrays: new and old keys, i
Mark Brownell
gizmotron at earthlink.net
Mon Sep 15 01:43:17 EDT 2008
-----Original Message-----
>From: Brian Yennie <briany at qldlearning.com>
>... On the other hand, if they are using something
>more like red-black trees, it is trivial to walk the tree in order and
>return the elements. Or backwards. Or "next" and "prev" functionality.
>But... I have no idea what data structure they are using.
>
Yes,
http://en.wikipedia.org/wiki/Red-black_tree
What will those clever people think of next.
If you know that the nodes have only two children, left or right, and that no nodes means that it is a leaf then you know to stop looking at the leaf.
You can do this yourself:
myTreeArray[1][1][2][1][1][2][2][2][1][2]
myNameSpaceArray[1][1][2][1][1][2][2][2][1][2]
You just run it parallel if it requires keys/names. The other option is to include namespace context at the front of all data being stored. Just include a logical delimiter. Yep, very interesting.
More information about the use-livecode
mailing list