Trees

Steven D'Aprano steve+comp.lang.python at pearwood.info
Tue Jan 20 00:08:25 CET 2015


Zachary Gilmartin wrote:

> Why aren't there trees in the python standard library?

Possibly because they aren't needed? Under what circumstances would you use
a tree instead of a list or a dict or combination of both?

That's not a rhetorical question. I am genuinely curious, what task do you
have that you think must be solved by a tree?

Also, what sort of tree? Binary tree? Binary search tree? Red/black tree?
AVL tree? Splay tree? B-tree? T-tree? Scapegoat tree? General n-ary tree?
Every possible type of tree yet invented?



-- 
Steven




More information about the Python-list mailing list