Tree: Postorder Traversal

  • + 0 comments

    JavaScript solution:

    function postOrder(root) {
    	if (root) {
            postOrder(root.left);
            postOrder(root.right);
            process.stdout.write(root.data + " ");
        }
    }