@@ -0,0 +1,1251 @@
+/**%0A * Definition for a binary tree node.%0A * public class TreeNode %7B%0A *     int val;%0A *     TreeNode left;%0A *     TreeNode right;%0A *     TreeNode(int x) %7B val = x; %7D%0A * %7D%0A */%0Aclass Solution %7B%0A    %0A    public List%3CInteger%3E postorderTraversal(TreeNode root) %7B%0A        List%3CInteger%3E res = new ArrayList%3CInteger%3E();%0A        %0A        if(root == null) %7B%0A            return res;%0A        %7D%0A        %0A        Stack%3CTreeNode%3E stack = new Stack%3CTreeNode%3E();%0A        stack.push(root);%0A        %0A        while(!stack.isEmpty())%7B%0A            TreeNode node = stack.pop();%0A            %0A            if(node.left != null) %7B%0A                stack.push(node.left);//%E5%92%8C%E4%BC%A0%E7%BB%9F%E5%85%88%E5%BA%8F%E9%81%8D%E5%8E%86%E4%B8%8D%E4%B8%80%E6%A0%B7%EF%BC%8C%E5%85%88%E5%B0%86%E5%B7%A6%E7%BB%93%E7%82%B9%E5%85%A5%E6%A0%88%0A            %7D%0A            if(node.right != null) %7B%0A                stack.push(node.right);//%E5%90%8E%E5%B0%86%E5%8F%B3%E7%BB%93%E7%82%B9%E5%85%A5%E6%A0%88%0A            %7D%0A            %0A            res.add(0,node.val);//%E9%80%86%E5%BA%8F%E6%B7%BB%E5%8A%A0%E7%BB%93%E7%82%B9%E5%80%BC%0A        %7D     %0A        %0A        return res;%0A    %7D%0A    %0A    /*public List%3CInteger%3E postorderTraversal(TreeNode root) %7B%0A        List%3CInteger%3E list = new ArrayList%3C%3E();%0A        %0A        if (root == null) %7B%0A            return list;%0A        %7D%0A        %0A        list.addAll(postorderTraversal(root.left));%0A        list.addAll(postorderTraversal(root.right));%0A        list.add(root.val);%0A        %0A        return list;%0A    %7D*/%0A%7D

add no.145