https://leetcode.com/problems/first-unique-character-in-a-string/ Given a string, find the first non-repeating character in it and return it's index. ...
分类:
其他好文 时间:
2019-01-30 20:54:02
阅读次数:
119
模板太多了,写啥更新啥,顺便当自己的存档 码风很乱,见谅 单点修改树状数组 Code</> 区间修改树状数组 Code</> 可持久化线段树(主席树) Code</> ...
分类:
其他好文 时间:
2019-01-30 20:30:53
阅读次数:
138
算法描述: The set [1,2,3,...,n] contains a total of n! unique permutations. By listing and labeling all of the permutations in order, we get the following ...
分类:
其他好文 时间:
2019-01-30 15:50:54
阅读次数:
99
Given an array nums of n integers and an integer target, are there elements a, b, c, and d in nums such that a + b + c + d = target? Find all unique q ...
分类:
其他好文 时间:
2019-01-30 14:25:47
阅读次数:
122
描述 写一个程序完成以下命令:new id ——新建一个指定编号为id的序列(id<10000)add id num——向编号为id的序列加入整数nummerge id1 id2——合并序列id1和id2中的数,并将id2清空unique id——去掉序列id中重复的元素out id ——从小到大输 ...
分类:
其他好文 时间:
2019-01-30 01:31:06
阅读次数:
233
https://leetcode.com/problems/top-k-frequent-elements/ Given a non-empty array of integers, return the k most frequent elements. Example 1: Example 2: ...
分类:
其他好文 时间:
2019-01-30 00:28:03
阅读次数:
132
F. MST Unification 题目传送门 题意: 给你n个顶点,m条边;保证没有重边,其中存在多个MST(最小生成树), 你可以修改一些边的权值,让其中有且仅有一个最小生成树,求最少操作的边数。 思路: 最小生成树算法的加工,我们从kruskal算法入手,kruskal就是先对边排序, 然后 ...
分类:
其他好文 时间:
2019-01-28 01:11:51
阅读次数:
177
算法描述: Given an array nums of n integers, are there elements a, b, c in nums such that a + b + c = 0? Find all unique triplets in the array which gives ...
分类:
其他好文 时间:
2019-01-27 19:16:40
阅读次数:
167
一、对当前的session使用oradebug命令: SQL> conn / as sysdba Connected. SQL> oradebug setmypid Statement processed. 或者对其他session做跟踪 --连接到一个外部服务进程,且pid=v$process.p ...
分类:
其他好文 时间:
2019-01-25 23:51:39
阅读次数:
280
题目链接:MST Unification 题意:给定一张连通的无向带权图。存在给边权加一的操作,求最少操作数,使得最小生成树唯一。 题解:最小生成树在算法导论中有这个性质: 把一个连通无向图的生成树边按权值递增排序,称排好序的边权列表为有序边权列表,则任意两棵最小生成树的有序边权列表是相同的。(算法 ...
分类:
其他好文 时间:
2019-01-25 21:01:55
阅读次数:
389