Legand: - not done + done / in progress -------------------------------------------------- + Parameterize priority_size as a class variable using a class factory or similar. + Make it work for min and max, not just min + node retrieval + find itself + unit test + Add arbitrary node deletion + find the smallest + delete the smallest + find the largest + delete the largest - Make it optionally keep the n smallest (largest) values only (probably via a wrapper class) + Improve the unit testing: should check for binary tree and heap invariants + change recursive methods to iterative? Recursion stack overflow is a possibility in the current code. Of course, it likely would be in an iterative implementation too - just not as soon. Also, function/method calls are slow in python - an iterative implementation might help performance + reverse_iterator + make it work like a dictionary! + make remove_min and remove_max return the (key, value) they're removing + change exceptions.LookupError to exceptions.KeyError, for consistency with dict type + allow _treap_node to optionally be in cython, since it does the heavy lifting and doesn't need iterators