@@ -0,0 +1,986 @@
+/**%0A * Given a binary tree, return the bottom-up level order traversal of its nodes' values.%0A * (ie, from left to right, level by level from leaf to root).%0A */%0Apublic class Solution %7B%0A  public List%3CList%3CInteger%3E%3E levelOrderBottom(TreeNode root) %7B%0A    Queue%3CTreeNode%3E q = new LinkedList%3CTreeNode%3E();%0A    List%3CList%3CInteger%3E%3E list = new ArrayList%3CList%3CInteger%3E%3E();%0A    if (root == null) return list;%0A%0A    List%3CInteger%3E temp = new ArrayList%3CInteger%3E();%0A    int cur = 1;%0A    int next = 0;%0A    q.add(root);%0A%0A    while (!q.isEmpty()) %7B%0A      TreeNode node = q.poll();%0A      temp.add(node.val);%0A      cur --;%0A%0A      if (cur == 0 && !temp.isEmpty()) %7B%0A        list.add(0, temp);%0A        temp = new ArrayList%3CInteger%3E();%0A      %7D%0A%0A      if (node.left != null) %7B%0A        q.add(node.left);%0A        next ++;%0A      %7D%0A%0A      if (node.right != null) %7B%0A        q.add(node.right);%0A        next ++;%0A      %7D%0A%0A      if (cur == 0) %7B%0A        cur = next;%0A        next = 0;%0A      %7D%0A    %7D%0A%0A    return list;%0A  %7D%0A%7D%0A

Add tree level order traversal ii