摘要: 二叉树是每个结点最多有两个子树的有序树。通常子树的根被称作“左子树”(left subtree)和“右子树”(right subtree),右边的总是大于左边的!二叉树的每个结点至多只有二棵子树(不存在出度大于2的结点),二叉树的子树有左右之分,次序不能颠倒。 1 function Node(num) 2 { 3 this.num = num; 4 this.count = 1; 5 this.pLeft = null; 6 this.pRight = null; 7 } 8 9 10 function createNode(value)11 {12 ... 阅读全文
posted @ 2013-06-30 00:10 投河自尽的鱼 阅读(1019) 评论(0) 推荐(0) 编辑