Get a NON thread-safe iterator over the nodes in the tree for a DFS ordering.
Get a NON thread-safe iterator over the nodes in the tree for a DFS ordering. Each iterator value contains the node in the tree and the depth (root has 0 depth). This iterator requires O(B * D) auxiliary space where B is the branching factor and D is the tree depth.
a NON thread-safe iterator over the nodes in the tree for a DFS ordering.
A tree with a map structure for the descendants data structure. Note: Map keys are invariant. We could make K contravariant and use existential types in the type lambda to make it so we could construct MapTree without having to specify the type in the root instance or leave instance.
key type of the map structure
type of the descendant data structure.