Re:What are the lesser known but cool data structures?
by jacquesm on Saturday May 22, 2010 @11:32PM
(#1371703)
Isn't that how clojure works?
[ Parent
| on HN ]
Re:What are the lesser known but cool data structures?
by lmkg on Sunday May 23, 2010 @01:02PM
(#1372572)
IIRC, clojure works with 64-ary trees, which are a different data structure, but both share the property that 'leaves' contain more than one object. An unrolled linked list node would have, say, 63 objects and a pointer to another node. A 64-ary tree node will either have 64 objects, or pointers to 64 other nodes. One important property is that because each middle node in the tree has 64 children instead of 2, the depth of the trees are very very shallow in practice.
However, it's possible that clojure uses this layout for arrays and a different ones for lists or other sequences.
Re:What are the lesser known but cool data structures?
by jacquesm on Sunday May 23, 2010 @03:40PM
(#1372829)
I found a link to the implementation details, you are correct:
http://blog.higher-order.net/2009/02/01/understanding-clojur...