⚡ This is the AMP version of this page.
View full version
Competitive programming templates
Published: 7/7/2025 | Updated: 5/23/2025
ArticulationPoint
BellmanFord
Bridges
Cycles in Directed Graph
Difference Array
Dijkstra
DSU
HLD
Kadane’s Algo
KMP
Lazy Segment Tree
LCA
Math template
MST
Next Greatest Element
Ordered Set
Modular arithmetic
Rabin Karp
Segment Tree
Sieve
Sparse Table
Strongly Connected Components
Ternary Search
Topological Sorting
Trie
← Back to full version