/** * Definition for binary tree * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(...
分类:
其他好文 时间:
2014-06-25 18:40:08
阅读次数:
182
The example below shows how to use VB form/control as a container application to display a PowerPoint slideshow. It as shows how to make use of an und...
The2-3 treeis also a search tree like thebinary search tree, but this tree tries to solve the problem of theunbalanced tree.Imagine that you have a bi...
分类:
其他好文 时间:
2014-06-25 17:28:52
阅读次数:
202
1)使用Package Control组件安装,然后直接在线安装按Ctrl+`调出console粘贴以下代码到底部命令行并回车:import urllib2,os;pf='Package Control.sublime-package';ipp=sublime.installed_packages_...
分类:
其他好文 时间:
2014-06-25 16:38:59
阅读次数:
133
AVLTree即(Adelson-Velskii-Landis Tree),是加了额外条件的二叉搜索树。其平衡条件的建立是为了确保整棵树的深度为O(nLogn)。平衡条件是任何节点的左右子树的高度相差不超过1.在下面的代码中,编程实现了AVL树的建立、查找、插入、删除、遍历等操作。采用C++类封装。...
分类:
编程语言 时间:
2014-06-25 13:32:44
阅读次数:
353
1、介绍 ?决策树(decision tree)是一种有监督的机器学习算法,是一个分类算法。在给定训练集的条件下,生成一个自顶而下的决策树,树的根为起点,树的叶子为样本的分类,从根到叶子的路径就是一个样本进行分类的过程。 ?下图为一个决策树的例子,见http://zh.wikipedia.org/w...
分类:
其他好文 时间:
2014-06-25 13:13:16
阅读次数:
172
2 初识CAPWAP 2.1 CAPWAP简介 说了半天CAPWAP,连全称都还没说,汗…… CAPWAP——Control And Provisioning of Wireless Access Points Protocol Specification。其由两个部分组成:CAPWAP协议和无线B...
分类:
其他好文 时间:
2014-06-25 13:02:19
阅读次数:
178
#include #include #include #include using namespace std; typedef struct Node { struct Node *next[10]; int flag; }Node,*Tree; int flag1; void Cre...
分类:
其他好文 时间:
2014-06-25 11:27:43
阅读次数:
154
trie -- suffix tree -- suffix automa 有这么一些应用场景:
即时响应用户输入的AJAX搜索框时, 显示候选列表。
搜索引擎的关键字个数统计。
后缀树(Suffix Tree): 从根到叶子表示一个后缀。
仅仅从这一个简单的描述,我们可以概念上解决下面的几个问题:
P:查找字符串o是否在字符串S中
A:若o在S中,则o必然是S的某个后缀...
分类:
其他好文 时间:
2014-06-25 08:47:36
阅读次数:
165
【题目】
Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number.
An example is the root-to-leaf path 1->2->3 which represents the number 123.
Find the total sum of all root-to-leaf numbers.
For example,
1
...
分类:
其他好文 时间:
2014-06-25 07:32:27
阅读次数:
209