-
Notifications
You must be signed in to change notification settings - Fork 2
Home
You could find my notes and templates of well-known algorithms in CP here.
-
SOS DP and iterate over all the subsets of a mask in O(3^n)
https://codeforces.com/blog/entry/45223 -
Zeta transformation
https://codeforces.com/blog/entry/72488 -
GCC optimization - speed up for Naive Algorithm
https://codeforces.com/blog/entry/66279 -
Expected value of the squared number of pips / Calculate EV(X^2)
https://codeforces.com/blog/entry/62792 -
Summation of GCD(i, j) / multiplicative function https://github.com/khanhvu207/competitiveprogramming/blob/master/VNSPOJ/gcdsum.cpp
-
Fast long long multiplication using c++ overflow trick
https://codeforces.com/blog/entry/15884 -
Convex hull trick
https://codeforces.com/blog/entry/63823
https://cp-algorithms.com/geometry/convex_hull_trick.html
Algorithm Live - Convex Hull Optimization
https://github.com/khanhvu207/competitiveprogramming/blob/master/Olympiad/APIO/2010/commando.cpp -
Random numbers generator mt19937
mt19937_64 rng(chrono::steady_clock::now().time_since_epoch().count());