xuanweiace
xuanweiace
全部文章
Codeforce~
2018暑假 第一周 训练2(1)
2018暑假 第三周 训练1(1)
2018暑假 第三周 训练2(1)
2018暑假 第五周 训练3(1)
bfs(6)
bzoj(2)
dfs(8)
dfs+剪枝(1)
Dijkstra算法(4)
FZU(1)
HDU(20)
HihoCoder(2)
Java(1)
KMP~(3)
luogu(1)
nyoj(1)
PAT(2)
POJ(11)
Python(1)
QDU_AP协会17级ST2(1)
SPOJ(1)
STL(3)
tarjan算法~~强连通分量(2)
tricks(2)
Trie字典树(2)
ZOJ(6)
三分(1)
二分(8)
二分图(2)
优先队列(2)
优秀模板(1)
分数规划(1)
分治(1)
创新实验室热身赛2(1)
前缀和(1)
剪枝(2)
动态规划(dp)(33)
匈牙利算法(1)
区间问题(2)
单源最短路(2)
单调栈(1)
博弈问题(3)
字符串问题(4)
尺取法(3)
差分数组(1)
并查集(2)
思维(28)
打表(2)
拓扑排序(2)
数学(4)
数论(4)
最小生成树(2)
最短路(2)
最近公共祖先(1)
未归档(607)
树的直径(1)
模拟(9)
母函数(1)
水题纪念(45)
牛客网(14)
状态压缩(2)
皮(1)
知识点(7)
线段树(4)
背包问题(1)
蓝桥杯(2)
贪心(17)
随笔(3)
随笔啊(1)
题解(1)
归档
标签
去牛客网
登录
/
注册
xuanweiace的博客
全部文章
/ Codeforce~
(共25篇)
【CodeForces - 1152C 】Neko does Maths(数学数论,lcm,gcd性质)
题干: 给出a,b<=1e9,你要找到最小的k使得lcm(a+k,b+k)尽可能小,如果有多个k给出同样的最小公倍数,输出最小的一个k。 解题报告: 因为题目中k太多了,先化简一下公式,假设a>b ,则gcd(a+k,b+k) == gcd(a+k,a+b); 下面给出一个简单证...
2019-07-15
0
643
【CodeForces - 190E】Counter Attack (补图bfs,卡常,dsu)
题干: 无向图中给定n个顶点,m条不存在的边(除了这m条边,其余都存在),求图的连通分量,及每个连通分量的大小。 解题报告: https://codeforces.com/blog/entry/4556 AC代码: #include<cstdio> #include<...
2019-04-08
0
650
【CodeChef - CLIQUED 】Bear and Clique Distances(建图,缩点技巧,思维)
题干: 解题报告: 主要就是在于怎么处理那个前K个点:组成一个团。换句话说,缩成一个点。先直接当成每个点多了k条边来处理,T了。想想也是啊,要是K=1e5,那就是1e10条边了。。刚开始尝试了半天缩点,后来发现其实不用,只需要把这k个点都连到一个新点上,最后再连回去,然后直接Dijkst...
2019-04-06
0
657
【CodeForces - 558C】Amr and Chemistry(位运算,bfs,计数,思维,tricks)
题干: Amr loves Chemistry, and specially doing experiments. He is preparing for a new interesting experiment. Amr has n different types of chemicals. ...
2019-03-02
0
575
【CodeForces - 520C】DNA Alignment (快速幂,思维)
题干: Vasya became interested in bioinformatics. He's going to write an article about similar cyclic DNA sequences, so he invented a new method for det...
2019-01-22
0
661
【CodeForces - 523C】Name Quest (模拟)
题干: A Martian boy is named s — he has got this name quite recently from his parents for his coming of age birthday. Now he enjoys looking for his nam...
2019-01-22
0
591
【CodeForces - 471B】MUH and Important Things (模拟,细节)
题干: It's time polar bears Menshykov and Uslada from the zoo of St. Petersburg and elephant Horace from the zoo of Kiev got down to business. In total...
2019-01-22
0
610
【CodeForces - 298D】Fish Weight (OAE思想,思维)
题干: It is known that there are k fish species in the polar ocean, numbered from 1 to k. They are sorted by non-decreasing order of their weight, whic...
2018-12-08
0
536
【CodeForces - 245H 】Queries for Number of Palindromes (带容斥的区间dp)
题干: You've got a string s = s1s2... s|s| of length |s|, consisting of lowercase English letters. There also are q queries, each query is described by...
2018-12-07
0
566
【CodeForces - 608D】Zuma(区间dp)
题干: Genos recently installed the game Zuma on his phone. In Zuma there exists a line of n gemstones, the i-th of which has color ci. The goal of the ...
2018-12-06
0
490
首页
上一页
1
2
3
下一页
末页