tree_level tree n { result " " }What it does:
returns the n-th level of a tree (where 0 is the root tree) as a list of treesDefined in: /web/philip/tcl/ad-trees.tcl
Source code:
if { [empty_string_p $tree] } { return $result } if { $n==0 } { lappend result $tree } else { foreach subtree [tail $tree] { set result [tree_level $subtree [expr $n-1] $result] } } return $result