783. 二叉搜索树结点最小距离 LeetCode783. Minimum Distance Between BST Nodes 题目描述 给定一个二叉搜索树的根结点 root , 返回树中任意两节点的差的最小值。 示例: 输入: root = [4,2,6,1,3,null,null] 输出: 1 ...
分类:
其他好文 时间:
2019-05-06 01:40:28
阅读次数:
158
https://www.cnblogs.com/grandyang/p/4340948.html O(n)的时间复杂度 滑动窗口 存储t中所有的字符和对应出现的次数。然后从s的头部开始滑动,遇到一个t中的字符就减一次,并且只要是次数大于0的情况,肯定是成功匹配了一个字符。直到所有成功匹配的字符个数等 ...
-(void)_test9{ /// RACCommand又叫命令 是用来收发数据的 监听按钮点击,网络请求。。。。 RACCommand * command = [[RACCommand alloc] initWithSignalBlock:^RACSignal * _Nonnull(id _Nu... ...
分类:
其他好文 时间:
2019-05-03 18:00:51
阅读次数:
136
Spring 优秀的开源框架 1.1 IoC是什么 Ioc—Inversion of Control,即“控制反转”,不是什么技术,而是一种设计思想。在Java开发中,Ioc意味着将你设计好的对象交给容器控制,而不是传统的在你的对象内部直接控制。如何理解好Ioc呢?理解好Ioc的关键是要明确“谁控制 ...
分类:
编程语言 时间:
2019-05-03 16:07:45
阅读次数:
116
#include using namespace std; int n,m,x,y; int e[9][9]; int root=1; int timex;//时间戳 int num[9],low[9],flag[9];//flag标记割点 int min(int a,int b){ if(a=nu... ...
分类:
编程语言 时间:
2019-05-02 21:44:51
阅读次数:
155
题目描述 Given two arrays A, B of length n and m separately, you have to merge them into only one array C (of length n + m) obeying the rule that the rela ...
分类:
其他好文 时间:
2019-05-02 18:35:52
阅读次数:
183
近期比较忙, 抽空出来5.1开源献礼. 但凡学习音频降噪算法的朋友,肯定看过一个算法. <<语音增强-理论与实践>> 中提及到基于对数的最小均方误差的降噪算法,也就是LogMMSE. 资料见: <<Speech enhancement using a minimum mean-square erro ...
分类:
编程语言 时间:
2019-05-02 00:02:55
阅读次数:
244
In an array containing only 0s and 1s, a bit flip consists of choosing a (contiguous) subarray of length and simultaneously changing every 0 in the su ...
分类:
其他好文 时间:
2019-04-30 01:08:50
阅读次数:
133
记录是为了更好的成长! 之前一直没弄明白DB中是null的话在前台怎么判断,到底是null还是undefined?做demo测试结果如下: DB: name = nullJS: name = nullconsole.dir(name) >>>> null console.dir(name == nu ...
分类:
数据库 时间:
2019-04-27 19:29:27
阅读次数:
165