AccessNodesByLayer accesses nodes layer by layer (2-D array), instead of printing the results as 1-D array.
()
| 120 | |
| 121 | // AccessNodesByLayer accesses nodes layer by layer (2-D array), instead of printing the results as 1-D array. |
| 122 | func (t *RB[T]) AccessNodesByLayer() [][]T { |
| 123 | return accessNodeByLayerHelper[T](t.Root, t._NIL) |
| 124 | } |
| 125 | |
| 126 | // Depth returns the calculated depth of a Red-Black tree |
| 127 | func (t *RB[T]) Depth() int { |
nothing calls this directly
no outgoing calls
no test coverage detected