_0107

package
v0.0.0-...-a49be92 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 20, 2024 License: MIT Imports: 1 Imported by: 0

README

二叉树的层序遍历 II

给你二叉树的根节点 root ,返回其节点值 自底向上的层序遍历 。 (即按从叶子节点所在层到根节点所在的层,逐层从左向右遍历)

示例 1:

``` 输入:root = [3,9,20,null,null,15,7] 输出:[[15,7],[9,20],[3]]


**示例 2:**

输入:root = [1] 输出:[[1]]


**示例 3:**

输入:root = [] 输出:[]




**提示:**

* 树中节点数目在范围 `[0, 2000]` 内
* `-1000 <= Node.val <= 1000`

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL