1 """ 2 Given a collection of intervals, merge all overlapping intervals. 3 Example 1: 4 Input: [[1,3],[2,6],[8,10],[15,18]] 5 Output: [[1,6],[8,10],[ ...
分类:
其他好文 时间:
2020-02-06 22:59:28
阅读次数:
72
D. Irreducible Anagrams time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Let's call two s ...
分类:
其他好文 时间:
2020-02-03 12:19:08
阅读次数:
167
1 """ 2 Invert a binary tree. 3 Example: 4 Input: 5 4 6 / \ 7 2 7 8 / \ / \ 9 1 3 6 9 10 Output: 11 4 12 / \ 13 7 2 14 / \ / \ 15 9 6 3 1 16 """ 17 cl ...
分类:
其他好文 时间:
2020-02-02 23:46:38
阅读次数:
71
验证二叉搜索树。题目即是题意。二叉搜索树的特性是对于每个node而言,他的左子树上任意节点都比他自身小,右子树上任意节点都比他自身大。这个题也是有两种做法,迭代和递归。时间空间复杂度都是O(n)。例子, Example 1: 2 / \ 1 3 Input: [2,1,3] Output: true ...
分类:
其他好文 时间:
2020-01-31 10:43:30
阅读次数:
66
B. Infinite Prefixes time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output You are given strin ...
分类:
其他好文 时间:
2020-01-31 00:33:00
阅读次数:
88
Boost Asio相关 Boost是一个C++可移植库,是对标准库的后备拓展,也是C++标准化进程的开发引擎之一。 Boost Asio是Boost库中的一个部分,Asio的全称为Asynchronous input and output(异步输入输出)的缩写。结合Boost的特点,Asio提供了 ...
分类:
编程语言 时间:
2020-01-30 14:39:29
阅读次数:
110
A. Display The Number time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You have a large el ...
分类:
其他好文 时间:
2020-01-30 14:33:31
阅读次数:
86
Convert a non-negative integer to its english words representation. Given input is guaranteed to be less than 231 - 1. Example 1: Input: 123 Output: " ...
分类:
其他好文 时间:
2020-01-29 10:50:06
阅读次数:
54
整数转换罗马数字。13题是正好相反。 题意是给一个整数,请把它转换成罗马数字。规则如下, Symbol Value I 1 V 5 X 10 L 50 C 100 D 500 M 1000 例子, Example 1: Input: 3 Output: "III" Example 2: Input: ...
分类:
其他好文 时间:
2020-01-29 10:16:44
阅读次数:
73
B Sum Problem Input Output Sample Input Sample Output WrongAnswer 修改后: C A + B Problem II Input c include int main() { int n,i; long long a=0,b =0; sc ...
分类:
其他好文 时间:
2020-01-28 17:30:04
阅读次数:
81