#1. find方法可以在一个较长的字符串中查找子串,他返回子串所在位置的最左端索引,如果没有找到则返回-1 a = 'abcdefghijk' print(a.find('abc')) #the result : 0 print(a.find('abc',10,100)) #the result ...
分类:
其他好文 时间:
2020-04-09 09:14:44
阅读次数:
82
struct union_find_set { int father[MAXN];//每个元素的祖先 union_find_set(int limit)//构造函数,对于每一个元素,其父亲初始化为它本身 { for(int i=1;i<=limit;i++) { father[i]=i; } } i ...
分类:
其他好文 时间:
2020-04-08 22:47:17
阅读次数:
89
这是一个非常经典的带权并查集,有两种写法。 1 边权并查集 规定一下,当x和y这条边的权值为0时,表示x和y是同类,当为1时,表示x吃y,当为2时,表示x被y吃。 一共有三种状态,如图,当A吃B,B吃C时,C必须吃A,路径压缩后,A被C吃。 然后就是带权并查集的模板了。 判断条件,当x和y在同一颗树 ...
分类:
其他好文 时间:
2020-04-08 22:17:26
阅读次数:
73
$(".delRow").addClass("focus").css("pointer-events","none"); $('.datagrid-cell-check').find('input').addClass("focus").css("pointer-events","none"); ...
分类:
其他好文 时间:
2020-04-08 13:38:54
阅读次数:
87
题目描述 Given the relations of all the activities of a project, you are supposed to find the earliest completion time of the project. Input Specification ...
分类:
其他好文 时间:
2020-04-08 12:23:10
阅读次数:
78
在未排序的数组中找到第 k 个最大的元素。请注意,你需要找的是数组排序后的第 k 个最大的元素,而不是第 k 个不同的元素。 示例 1: 输入: [3,2,1,5,6,4] 和 k = 2 输出: 5 示例 2: 输入: [3,2,3,1,2,4,5,5,6] 和 k = 4 输出: 4 说明: 你 ...
分类:
编程语言 时间:
2020-04-08 12:22:50
阅读次数:
80
BusyBox是一个集成了三百多个最常用Linux命令和工具的软件。
BusyBox包含了一些简单的工具,例如ls、cat和echo等等,还包含了一些更大、更复杂的工具,例grep、find、mount以及telnet。有些人将BusyBox称为Linux工具里的瑞士刀。
分类:
其他好文 时间:
2020-04-07 20:44:18
阅读次数:
77
BusyBox是一个集成了三百多个最常用Linux命令和工具的软件。
BusyBox包含了一些简单的工具,例如ls、cat和echo等等,还包含了一些更大、更复杂的工具,例grep、find、mount以及telnet。有些人将BusyBox称为Linux工具里的瑞士军刀。
分类:
其他好文 时间:
2020-04-07 20:40:51
阅读次数:
65
执行 pip install pyautogui 提示: Could not find a version that satisfies the requirement Pillow>=6.2.1 (from pyscreeze>=0.1.21->pyautogui) (from versions: ...
分类:
编程语言 时间:
2020-04-07 18:13:23
阅读次数:
215
Find out which version of Microsoft Edge you have Here's how: Open the new Microsoft Edge , select Settings and more at the top of the window, and the ...
分类:
其他好文 时间:
2020-04-07 15:47:43
阅读次数:
1319