Hello all,

I’ve been practicing at Codechef for a while and now I’m gradually moving toward medium/hard problems. However many algorithms at these levels are very difficult to predict, and I was always stuck because I’m not aware of them. So I open this topic, my hope is to have a wish-list of most used algorithm for online programming contest that I can look up for reference. Here is my short-list up to now:

- Segment tree (with lazy propagation)
- Interval Tree
- Binary Indexed Tree
- Fast Modulo Multiplication (Exponential Squaring)
- Heuristic Algorithms
- KMP string searching
- Manacher’s Algorithm
- Union Find/Disjoint Set
- Trie
- Prime Miller Rabin
- Matrix Recurrence + Fast Modulo Multiplication for counting
- Stable Marriage Problem
- Extended Euclid’s algorithm
- Ternary Search
- Fast Fourier Transform for fast polynomial multiplication
- Djikstra’s algorithm, Bellman-ford algorithm, Floyd-Warshall Algorithm
- Prim’s Algorithm, Kruskal’s Algorithm
- RMQ, LCA
- Flow related algorithms, assignment problem, Hungarian algorithm
- Bipartite matching algorithms
- Heavy-light decomposition
- Sweep line algorithm
- Z algorithm
- Convex Hull
- Suffix Arrays
- LCP
- Suffix Tree
- Gaussian Elimination
- Numerical Integration/Differentiation
- Line Clipping
- Advanced Maths Ad-Hoc problems
- Aho–Corasick string matching algorithm;
- Calculate nCr % M Lucas’s Theorem
- Heavy Light decomposition in trees
- Inverse Modulo operations
- Pollard Rho Integer Factorization
- Catalan Numbers

Add some more…