- 博客(15)
- 收藏
- 关注
原创 HDU 6184 Counting Stars 三元环计数
Counting Stars题目意思:给你一个图,问你有多少个子图是一个四边形加一个对角线。思路:枚举对角线,即枚举每一条边,如果存在两个不同的点,和这条边上的两点都相邻的话,这不就是我们所需要的图形吗?直接开bitset,然后&一下,飞快的过了样例,交上去,飞快的MLE了。那咋办啊?问大佬去了,大佬直接一句三元环傻逼题,就把我扔走了,,,w(゚Д゚)w留下了自...
2019-05-29 11:57:54
325
原创 字符串水题
HDU - 1686给A串B串,求A串在B串中出现次数。A串kmp预处理,然后再对A,B比较,用j表示匹配时A串的pos,则当j>=strlen(A)时候,ans++;HDU - 2087给A串和B串,求从A串中能割出来多少个B串。对A串和B串进行预处理,这个kmp_next数组是基于A和B串的。即正常的kmp是对同一个串的前缀和当前位置进行比...
2019-04-11 23:23:31
345
原创 NCPC2018 Delivery Delays
题意:你经营着一家披萨店,该披萨店在1号点,每天都会有很多的订单,第i个订单是在si时刻发来的,收货地点在ui,该披萨在ti时刻才可以做好。问你每个订单的收货时间-发出时间(即买家等待时间)的最大值 的最小值 是多少。即用dp[i]表示第i个订单,让你最小化 Max{dp[i]-s[i]}。数据输入:第一行:n(点的数目,n<=1000),m(边的数目,m<=5000...
2019-03-14 13:56:44
427
原创 2018 icpc 青岛现场赛(训练用) 嘴炮记录
C - Flippy Sequence 水题#include<bits/stdc++.h>using namespace std;int a[10000000];bool c[10000000];int main(){ int T; scanf("%d",&T); int n; int cnt; long long l...
2018-12-10 22:30:04
308
转载 超神读入挂
收割成功namespace fastIO{ #define BUF_SIZE 100000 #define OUT_SIZE 100000 #define ll long long //fread->read bool IOerror=0; inline char nc(){ static char buf[BUF_SIZ...
2018-08-18 13:31:13
307
原创 2018杭电多校 第五场 1007补题 线段树
少壮不努力,自挂线段树。被打的自闭成环了,唉。 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=6356AC(跑的死慢的)代码#include<bits/stdc++.h>#define INF 0x3f3f3f3f#define lson l, mid, pos<<1#define rson mid...
2018-08-07 15:48:14
268
原创 2018杭电多校第四场 1002 Harvest of Apples 莫队大法好~
Problem B. Harvest of ApplesTime Limit: 4000/2000 MS (Java/Others) Memory Limit: 262144/262144 K (Java/Others)Total Submission(s): 1169 Accepted Submission(s): 443Problem DescriptionThere...
2018-08-02 10:43:55
292
原创 HNU校内训练 Skeletons Tehran 2016 反向建边
抱歉没时间仔细讲解,先mark一下,以后再更。 S keletons Time Limit: 10000ms, Special Time Limit:25000ms, Memory Limit:524288KB Total submit users: 6, Accepted users: 1 Problem 14126 : No special judge...
2018-07-31 09:11:58
446
原创 2018杭电多校第一场补题1008 RMQ Similar Sequence 笛卡尔树
RMQ Similar SequenceTime Limit: 4000/2000 MS (Java/Others) Memory Limit: 255535/255535 K (Java/Others)Total Submission(s): 231 Accepted Submission(s): 41 Problem DescriptionChiaki has a ...
2018-07-26 10:11:40
274
原创 2018杭电多校第二场补题 1005 Hack It 数论
Hack ItTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 450 Accepted Submission(s): 130Special Judge Problem DescriptionTonyfang is a ...
2018-07-26 09:25:49
865
1
原创 HDOJ2018多校第一场补题1007 Chiaki Sequence Revisted
emmmmmm事先声明下,这题不是我补的,毕竟对于数学八字不合,是我队友补的,然后,由于B站优良的学习氛围,他选择了在B站上发,我就当个板砖工了~B站链接:https://www.bilibili.com/read/cv795958 题意是,给了一个数列的递推公式,让我们求前缀和Sn,一共有T组case,Sn可能很大,答案对10^9+7取余数,n为 <= 10^18的正整...
2018-07-25 00:14:06
429
原创 2018杭电多校第一场补题1002 Balanced Sequence 流水线排序
Balanced SequenceTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1469 Accepted Submission(s): 155 Problem DescriptionChiaki has n str...
2018-07-24 09:48:48
330
原创 湖北省大学程序设计竞赛(网络同步赛) D. Who killed Cock Robin
链接:https://www.nowcoder.com/acm/contest/104/C来源:牛客网题目描述 Who killed Cock Robin? I, said the Sparrow, With my bow and arrow,I killed Cock Robin. Who saw him die? I, said the F...
2018-04-22 18:51:47
346
原创 ATRC2017 Column Addition
DescriptionA multi-digit column addition is a formula on adding two integers written like this:A multi-digit column addition is written on the blackboard, but the sum is not necessarily correct. We ca...
2018-04-09 12:16:29
497
原创 Artwork NCPC 2016
DescriptionA template for an artwork is a white grid of n × m squares. The artwork will be created by painting q horizontal and vertical black strokes. A stroke starts from square (x1, y1), ends at sq...
2018-04-05 12:03:33
546
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人