Hi,

Am 30.06.2009 um 09:05 schrieb Emeka:

I have a BinaryTree Nodes that I want to resolve it's depth and the BinaryTree may be unbalanced. How do I do this? Can't just figure it out on my own? It is in the form of vector of vectors, and from one cell of any vector I can move to the next row however the column index has to be either increased by one or decreased by one(and the new cell is empty).

I'm not an algorithm specialist for such things,
but you might want to look into clojure.zip (in
particular clojure.zip/vector-zip). You can
traverse the tree keeping the max depth as
you go.

Sincerely
Meikel

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to