(node)
Recursively yield all descendant nodes in the tree starting at *node*
    (including *node* itself), in no specified order.  This is useful if you
    only want to modify nodes in place and don't care about the context.
Recursively yield all descendant nodes in the tree starting at *node*
    (including *node* itself), in no specified order.  This is useful if you
    only want to modify nodes in place and don't care about the context.
Recursively yield all descendant nodes in the tree starting at * node * ( including * node * itself ) in no specified order . This is useful if you only want to modify nodes in place and don t care about the context .
def walk(node):
    """
    Recursively yield all descendant nodes in the tree starting at *node*
    (including *node* itself), in no specified order.  This is useful if you
    only want to modify nodes in place and don't care about the context.
    """
    from collections import deque
    todo = deque([node])
    while todo:
        node = todo.popleft()
        todo.extend(iter_child_nodes(node))
        yield node
def walk ( node ) : from collections import deque todo = deque ( [ node ] ) while todo : node = todo . popleft ( ) todo . extend ( iter_child_nodes ( node ) ) yield node