module
Version:
v0.0.0-...-2922d23
Opens a new window with list of versions in this module.
Published: Sep 10, 2021
License: CC0-1.0
Opens a new window with license information.
README
¶
go-algorithm
Algorithms and Data Structures in Golang.
These libraries are assumed to be used in competitive programming, so errors are not handled strictly.
Categories |
Examples |
Standard Library |
Max/Min, Binary Search, Next Permutation, Standard Data Structure Examples |
Data Structure |
Set, Queue, Stack, UnionFind, Segment Tree, Binary Indexed Tree |
Dynamic Programming |
Knapsack, Bit, Digit |
Graph |
Dijkstra, Floyd Warshall, Minimum Spanning Tree |
Mathematics |
Binomial Coefficient, Prime Numbers, Eratosthenes |
Sorting |
Insertion, Merge, Heap, Quick, Base |
Standard Library
Standard Libraries in C++.
STL Function
- Abs
- GCD
- LCM
- Max
- Min
- Binary Search
- Next Permutation
- Pop Count (Only Example)
- Reverse (Only Example)
- Sort (Only Example)
STL Data Structure
We can simply create the following data structures
by built-in structs such as map and slice.
If you want to implement set, queue and stack yourself,
please refer to Data Structure directory.
- Set (Only Example)
- Queue (Only Example)
- Stack (Only Example)
- Priority Queue (Int Heap)
Dynamic Programming
Data Structure
- Set
- Queue
- Stack
- Priority Queue
- UnionFind
- Segment Tree
- Binary Indexed Tree
Graph
- Dijkstra
- Floyd Warshall
- Minimum Spanning Tree - Prim
- Minimum Spanning Tree - Kruskal
Mathematics
Combinatorics
Number Theory
- Modulo Power
- Divisor
- Primality Test
- Integer Factorization
- Sieve of Eratosthenes
Sorting
- Insertion
- Merge
- Heap
- Quick
- Base
- Bucket
Directories
¶
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
stl
|
|
|
|
|
|
Click to show internal directories.
Click to hide internal directories.