Skip to content

Instantly share code, notes, and snippets.

function BinarySearchTree () {
this._root = null;
}
BinarySearchTree.prototype = {
constructor: BinarySearchTree,
/**
* find the min number of the tree
/**
* 中缀表达式转后缀表达式
*/
function isOperator (item) {
return item === '+' || item === '-' || item === '*' || item === '/' || item === '(' || item === ')';
}
function convert (str) {
var output = [],
stack = [],
operator;