Given a non-empty special binary tree consisting of nodes with the non-negative value, where each node in this tree has exactly two or zero sub-node. ...
分类:
其他好文 时间:
2019-12-07 21:15:30
阅读次数:
99
Python 二分查找 二分搜索是一种在有序数组中查找某一特定元素的搜索算法。搜索过程从数组的中间元素开始,如果中间元素正好是要查找的元素,则搜索过程结束;如果某一特定元素大于或者小于中间元素,则在数组大于或小于中间元素的那一半中查找,而且跟开始一样从中间元素开始比较。如果在某一步骤数组为空,则代表 ...
分类:
其他好文 时间:
2019-12-07 21:08:07
阅读次数:
104
Given a binary tree, imagine yourself standing on the right side of it, return the values of the nodes you can see ordered from top to bottom. Example ...
分类:
其他好文 时间:
2019-12-07 12:18:43
阅读次数:
81
"Contest Link" easy: ABDGIJ medium easy: E medium: H medium hard: CF A. Cool number 各数位之和不大,枚举即可。 E. Binary Search Tree 考虑 DP,$f[u]$ 表示以 $u$ 为根,极大合法连通 ...
分类:
其他好文 时间:
2019-12-07 10:55:11
阅读次数:
88
Given a binary search tree, write a function kthSmallest to find the kth smallest element in it. Note:You may assume k is always valid, 1 ≤ k ≤ BST's ...
分类:
其他好文 时间:
2019-12-07 10:18:19
阅读次数:
76
SELECT top(10) * from (SELECT sys.fn_cdc_map_lsn_to_time([__$start_lsn]) 'addtime',* FROM cdc.dbo_TM_Room_CT)awhere 0=0 列名 数据类型 说明 __$start_lsn binary ...
分类:
数据库 时间:
2019-12-06 19:04:03
阅读次数:
239
* @lc app=leetcode.cn id=236 lang=cpp * * [236] 二叉树的最近公共祖先 * * https://leetcode-cn.com/problems/lowest-common-ancestor-of-a-binary-tree/description/ * ...
分类:
其他好文 时间:
2019-12-06 13:49:58
阅读次数:
88
一、MySQL主从复制原理 主从同步过程中主服务器有一个工作线程I/O dump thread,从服务器有两个工作线程I/O thread和SQL thread; 主服务器: dump Thread:为每个Slave的I/O Thread启动一个dump线程,用于向其发送binary log eve ...
分类:
数据库 时间:
2019-12-06 00:10:01
阅读次数:
101
Given a binary tree, return the inorder traversal of its nodes' values. Example: Follow up: Recursive solution is trivial, could you do it iteratively ...
分类:
移动开发 时间:
2019-12-05 22:48:52
阅读次数:
215
1、算法 SnowFlake算法生成的数据组成结构如下: 在java中用long类型标识,共64位(每部分用 分开): 0 0000000000 0000000000 0000000000 0000000000 0 00000 00000 0000000000 00 1位标识,0表示正数。 41位时 ...
分类:
编程语言 时间:
2019-12-05 22:42:50
阅读次数:
104