LINK: "Security" 求一个严格大于T的字符串 是原字符串S[L,R]的子串。 容易想到尽可能和T相同 然后再补一个尽可能小的字符即可。 出于这种思想 可以在SAM上先跑匹配 然后枚举加哪个字符 判定即可。 判定s是否在[L,R]中出现过 最快的方法 就是right集了。 这个可以线段树 ...
分类:
其他好文 时间:
2020-05-05 20:11:36
阅读次数:
61
快速排序(ES6) function qSort(arr){ if(arr.length <= 1){return arr} const mVal = arr.shift() //这是基准数,比这小的放左边数组, 比这大的放在右边 let [left, right] = [[], []] arr.f ...
分类:
编程语言 时间:
2020-05-05 19:57:20
阅读次数:
115
题目: 解答: 1 class Solution { 2 public: 3 int searchInsert(vector<int> &nums, int target) 4 { 5 int left = 0; 6 int right = nums.size() - 1; 7 8 while(le ...
分类:
其他好文 时间:
2020-05-05 12:40:50
阅读次数:
49
[TOC] html5用法 一、基础用法 标签对齐属性设置:align="right/left/center",默认是left,当设置成right时标签右对齐。 target="_blank" :当点击超链接时在新的页面中打开,如果不设置target,则超链接页面会覆盖掉当前页面,不会在新页面中打开 ...
分类:
Web程序 时间:
2020-05-04 19:25:16
阅读次数:
71
width:0; height:0; border:100px solid; border-top-color:red; border-right-color:transparent; border-bottom-color:transparent; border-left-color:transp ...
分类:
Web程序 时间:
2020-05-04 13:27:12
阅读次数:
58
我们在编写一个查询语句的时候 SELECT DISTINCT < select_list > FROM < left_table > < join_type > JOIN < right_table > ON < join_condition > WHERE < where_condition > ...
分类:
数据库 时间:
2020-05-04 01:08:27
阅读次数:
93
题目: 解答: 1 class Solution { 2 public: 3 int removePalindromeSub(string s) 4 { 5 if (s.size() == 0) 6 { 7 return 0; 8 } 9 for (int left = 0, right = s.s ...
分类:
其他好文 时间:
2020-05-04 00:29:41
阅读次数:
61
题目: 解答: 同题目530。 1 /** 2 * Definition for a binary tree node. 3 * struct TreeNode { 4 * int val; 5 * TreeNode *left; 6 * TreeNode *right; 7 * TreeNode( ...
分类:
其他好文 时间:
2020-05-03 16:47:37
阅读次数:
52
题目: 解答: 1 /** 2 * Definition for a binary tree node. 3 * struct TreeNode { 4 * int val; 5 * TreeNode *left; 6 * TreeNode *right; 7 * TreeNode(int x) : ...
分类:
其他好文 时间:
2020-05-03 16:30:10
阅读次数:
38
题目: 解答: 1 /** 2 * Definition for a binary tree node. 3 * public class TreeNode { 4 * int val; 5 * TreeNode left; 6 * TreeNode right; 7 * TreeNode(int ...
分类:
其他好文 时间:
2020-05-03 16:21:26
阅读次数:
53