Concepts5
∑MathIntermediate
Stars and Bars
Stars and Bars counts the ways to distribute n identical items into k distinct bins using combinations.
#stars and bars#combinatorics#binomial coefficient+12
∑MathIntermediate
Sieve of Eratosthenes
The Sieve of Eratosthenes marks multiples of each prime to find all primes up to n in O(n log log n) time.
#sieve of eratosthenes#segmented sieve#linear sieve+11
∑MathIntermediate
GCD and Euclidean Algorithm
The greatest common divisor (gcd) of two integers is the largest integer that divides both without a remainder.
#gcd#euclidean algorithm#extended euclidean+12
∑MathAdvanced
Gaussian Elimination over GF(2)
Gaussian elimination over GF(2) is ordinary Gaussian elimination where addition and subtraction are XOR and multiplication is AND.
#gaussian elimination#gf(2)#xor basis+12
∑MathAdvanced
Linear Recurrence
A linear recurrence defines each term as a fixed linear combination of a small, fixed number of previous terms.
#linear recurrence#matrix exponentiation#kitamasa+12