Eterna_King

导航

2019年3月16日 #

SP3871 GCDEX - GCD Extreme

摘要: //author Eterna #define Hello the_cruel_world! #pragma GCC optimize(2) #include #include #include #include #include #include #include #include #include #include #include #include #include #include #i... 阅读全文

posted @ 2019-03-16 18:09 Eterna_King 阅读(185) 评论(0) 推荐(0) 编辑

P2930 [USACO09HOL]假期绘画Holiday Painting

摘要: 线段树水题,考虑到只有15列,所以我们对于每一列,我们都去维护一个线段树。 现在来考虑一下修改操作,因为每次修改的时候,我们都是将黑的改成白的,白的改成黑的,所以我们对线段树的每个节点维护当前这段区间和原来颜色相同的点的个数,所以每次改成白色我们只需要找原来是白色的总数,或者黑色,所以就特别简单了。 阅读全文

posted @ 2019-03-16 17:26 Eterna_King 阅读(247) 评论(0) 推荐(0) 编辑

二维平面计算几何模板

摘要: 1 //author Eterna 2 #include<iostream> 3 #include<algorithm> 4 #include<cstdio> 5 #include<vector> 6 #include<cstring> 7 #include<string> 8 #include<c 阅读全文

posted @ 2019-03-16 16:38 Eterna_King 阅读(223) 评论(0) 推荐(0) 编辑

扩展卢卡斯定理

摘要: 1 //author Eterna 2 #define Hello the_cruel_world! 3 #pragma GCC optimize(2) 4 #include<iostream> 5 #include<algorithm> 6 #include<cstdio> 7 #include< 阅读全文

posted @ 2019-03-16 16:37 Eterna_King 阅读(126) 评论(0) 推荐(0) 编辑

无旋treap

摘要: 1 #ifndef FHQTREAP_H_INCLUDED 2 #define FHQTREAP_H_INCLUDED 3 4 //author Eterna 5 #define Hello The_Cruel_World! 6 #pragma GCC optimize(2) 7 #include< 阅读全文

posted @ 2019-03-16 16:37 Eterna_King 阅读(119) 评论(0) 推荐(0) 编辑

扩展中国剩余定理

摘要: 1 //author Eterna 2 #define Hello the_cruel_world! 3 #pragma GCC optimize(2) 4 #include<iostream> 5 #include<algorithm> 6 #include<cstdio> 7 #include< 阅读全文

posted @ 2019-03-16 16:36 Eterna_King 阅读(149) 评论(0) 推荐(0) 编辑

中国剩余定理

摘要: 1 //author Eterna 2 #define Hello the_cruel_world! 3 #pragma GCC optimize(2) 4 #include<iostream> 5 #include<algorithm> 6 #include<cstdio> 7 #include< 阅读全文

posted @ 2019-03-16 16:36 Eterna_King 阅读(137) 评论(0) 推荐(0) 编辑

ex_BSGS

摘要: //author Eterna #define Hello the_cruel_world! #pragma GCC optimize(2) #include #include #include #include #include #include #include #include #include #include #include #include #include #include #i... 阅读全文

posted @ 2019-03-16 16:34 Eterna_King 阅读(191) 评论(0) 推荐(0) 编辑

BSGS模板(慢速)

摘要: //author Eterna #define Hello the_cruel_world! #pragma GCC optimize(2) #include #include #include #include #include #include #include #include #include #include #include #include #include #include #i... 阅读全文

posted @ 2019-03-16 16:33 Eterna_King 阅读(128) 评论(0) 推荐(0) 编辑