#include<iostream> #include<cstring> #include<cmath> #include<cstdio> #include<algorithm> #include<stack> #include<queue> using namespace std; const i ...
分类:
其他好文 时间:
2020-01-28 15:34:42
阅读次数:
71
最大流模板题 注意反向边的意义。 #include<bits/stdc++.h> using namespace std; const int INF = 1e9; const int MAXN = 301; int ma[MAXN][MAXN],pre[MAXN]; int n,m; int bf ...
分类:
其他好文 时间:
2020-01-28 12:16:36
阅读次数:
63
ACboy needs your help again! Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 16823 Accepted Submi ...
分类:
其他好文 时间:
2020-01-27 22:24:33
阅读次数:
94
Text Reverse Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 51495 Accepted Submission(s): 19692 ...
分类:
其他好文 时间:
2020-01-27 21:59:24
阅读次数:
67
圆桌问题 Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 6252 Accepted Submission(s): 2380 Problem De ...
分类:
其他好文 时间:
2020-01-27 21:54:12
阅读次数:
82
最近家庭聚会也真不少,为啥做题这么应景... 水题,加上集合的利用,并查集 ...
分类:
其他好文 时间:
2020-01-27 18:50:08
阅读次数:
68
https://vjudge.net/contest/353156#problem/A 一开始想着按背包做 = = 我的dp还是太菜了 应该按照单调序列做 1 #include <iostream> 2 #include <algorithm> 3 #include <vector> 4 using ...
分类:
其他好文 时间:
2020-01-27 13:48:24
阅读次数:
59
为提高工作效率,让多个爬虫一起工作 需要使用的库是:gevent 方式一 1.使用队列的形式: from gevent import monkey # 从gevent库里导入monkey模块。 monkey.patch_all() # monkey.patch_all()能把程序变成协作式运行,就是 ...
分类:
其他好文 时间:
2020-01-26 23:51:48
阅读次数:
174
题意:有T个样例,每个样例输入两个数 a 和 b,让你找到一个数,使得 a + x = c, b + x = d, c 和 d 是质数并且相邻。 解法:打素数表(埃式筛法) 不成立: (b - a)&1 或 b == a 成立: 特殊: a = 1 , b = 2, ans = 1; a = 2, ...
分类:
其他好文 时间:
2020-01-26 20:42:12
阅读次数:
66
一、gevent实现某函数异步并发 工作应用:如爬虫,下载是一个函数f1,解析是一个函数f2,都通过spawn住,然后通过 从而实现协程并发! ...
分类:
编程语言 时间:
2020-01-26 17:38:57
阅读次数:
108