public ArrayList<ArrayList<Integer>> levelOrderBottom_lint(TreeNode root) {
        ArrayList<ArrayList<Integer>> res = new ArrayList<ArrayList<Integer>>();
        if (root == null)
            return res;
        Queue<TreeNode> queue = new LinkedList<TreeNode>();
        queue.offer(root);
        while (!queue.isEmpty()) {
            int size = queue.size();
            ArrayList<Integer> temp = new ArrayList<Integer>();
            while (size-- > 0) {
                TreeNode cur = queue.poll();
                temp.add(cur.val);
                if (cur.left != null)
                    queue.offer(cur.left);
                if (cur.right !=null)
                    queue.offer(cur.right);
            }
            res.add(temp);
        }
        Collections.reverse(res);
        return res;
    }