Monday, September 29, 2014

Binary Tree Level Order Traversal II

Problem

Given a binary tree, return the bottom-up level order traversal of its nodes' values. (ie, from left to right, level by level from leaf to root).

For example:

Idea

做法与binary tree level order traversal 类似。不同的地方是别忘记把结果倒过来.

Solution


No comments:

Post a Comment