码迷,mamicode.com
首页 >  
搜索关键字:minimal ratio tree    ( 19189个结果
第十章 基本数据结构 练习 10.4-4
package chap10;import static org.junit.Assert.*;import java.util.Stack;import org.junit.Test;public class exec10_4_4 { /** * 将该树打印 * * @param tree */ ...
分类:其他好文   时间:2014-06-16 10:58:06    阅读次数:183
树状数组
一、树状数组树状数组是一个优美小巧的数据结构,在很多时候可以代替线段树。一句话概括就是,凡是树状数组可以解决的问题,线段树都可以解决,反过来线段树可以解决的问题,树状数组不一定能解决。树状数组英文名称为Binary Index Tree,直译过来就是二进制索引树,我觉得二进制索引树更能说明其本质。树...
分类:其他好文   时间:2014-06-16 07:24:03    阅读次数:190
二叉搜索树实现MAP
二叉搜索树的基本实现。 1 /* 2 Date: 2014-04-29 3 purpose: An implementation of MAP using binary search tree. 4 */ 5 6 #ifndef CUSTOMIZED_MAP_H 7 #define CUST...
分类:其他好文   时间:2014-06-12 15:59:38    阅读次数:404
[leetcode]Maximum Depth of Binary Tree @ Python
原题地址:https://oj.leetcode.com/problems/maximum-depth-of-binary-tree/题意:Given a binary tree, find its maximum depth.The maximum depth is the number of n...
分类:编程语言   时间:2014-06-12 13:55:34    阅读次数:210
Leetcode | Balanced Binary Tree
Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary tree in which the depth...
分类:其他好文   时间:2014-06-12 08:10:28    阅读次数:194
Careercup | Chapter 4
二叉查换树,左孩子小于等于根,右孩子大于根。完全二叉树,叶子都在最后一层,所有结点(除了叶子)都有两个孩子。平衡二叉树,左右子树的高度在一定范围内。4.1 Implement a function to check if a binary tree is balanced. For the purp...
分类:其他好文   时间:2014-06-12 08:09:04    阅读次数:167
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!