原创 Codeforces Round #705 (Div. 2)C. K-beautiful Strings(貪心)
https://codeforces.com/contest/1493/problem/C 從後往左找一個需要加大的地方,枚舉這個地方加大多少,每次都判定後面是否能湊成功即可 1 #define IO std::ios::sync_w
原创 Codeforces Round #705 (Div. 2)D. GCD of an Array (multiset)
https://codeforces.com/contest/1493/problem/D 1 #define IO std::ios::sync_with_stdio(0),cin.tie(0),cout.tie(0); 2 #
原创 Codeforces Global Round 13 C題(差分)
https://codeforces.com/contest/1491/problem/C 貪心,從左往右每一輪只需要每個長度跳第一次,可以用差分數組維護每個點被踩的次數。 1 #define IO std::ios::sync_wit
原创 SPOJ Favorite Dice(期望DP入門)
https://vjudge.net/problem/SPOJ-FAVDICE https://blog.csdn.net/myjs999/article/details/81022546 1 #define IO std::ios::
原创 protobuf+RPC技術
https://zhuanlan.zhihu.com/p/136891972
原创 配置sublime寫C++教程
先配置mingw https://sourceforge.net/projects/mingw-w64/files/Toolchains%20targetting%20Win64/Personal%20Builds/mingw-builds
原创 Codeforces Round #702 (Div. 3)G(二分,模擬stl)
https://codeforces.com/contest/1490/problem/G 二分循環幾輪,再二分哪個位置剛好夠。 1 #define IO std::ios::sync_with_stdio(0),cin.tie(0)
原创 Codeforces Round #703 (Div. 2)D(二分,前綴和)
https://codeforces.com/contest/1486/problem/D 1 #define IO std::ios::sync_with_stdio(0),cin.tie(0),cout.tie(0); 2 #de
原创 Codeforces Round #703 (Div. 2)C (二分)
https://codeforces.com/contest/1486/problem/C2 1 #define IO std::ios::sync_with_stdio(0),cin.tie(0),cout.tie(0); 2 #d
原创 Educational Codeforces Round 102 (Rated for Div. 2)E題(分層圖、最短路)
https://codeforces.com/contest/1473/problem/E vector存圖: 1 #define bug(x) cout<<#x<<" is "<<x<<endl 2 #define IO std
原创 pipioj 1466: PIPI撿垃圾Ⅱ(平衡樹or權值線段樹)
看了羣友的平衡樹stl板子,學到了orz 1 #define bug(x) cout<<#x<<" is "<<x<<endl 2 #define IO std::ios::sync_with_stdio(0) 3 #include
原创 pipioj 1454: 網絡工程師(kruskal)
1 #define bug(x) cout<<#x<<" is "<<x<<endl 2 #define IO std::ios::sync_with_stdio(0) 3 #include <bits/stdc++.h> 4 u
原创 pipioj 1452: 括號匹配Ⅱ(貪心)
1 #define bug(x) cout<<#x<<" is "<<x<<endl 2 #define IO std::ios::sync_with_stdio(0) 3 #include <bits/stdc++.h> 4 u
原创 pipioj 1453: 魔術師PIPIⅡ(bfs)
1 #define bug(x) cout<<#x<<" is "<<x<<endl 2 #define IO std::ios::sync_with_stdio(0) 3 #include <bits/stdc++.h> 4 u
原创 pipioj 1039: 重複子序列問題(貪心)
1 #define bug(x) cout<<#x<<" is "<<x<<endl 2 #define IO std::ios::sync_with_stdio(0) 3 #include <bits/stdc++.h> 4 u