🎓How I Study AIHISA
📖Read
📄Papers📰Blogs🎬Courses
💡Learn
🛤️Paths📚Topics💡Concepts🎴Shorts
🎯Practice
🧩Problems🎯Prompts🧠Review
Search

Concepts4

Category

🔷All∑Math⚙️Algo🗂️DS📚Theory

Level

AllBeginnerIntermediateAdvanced
Filtering by:
#fast exponentiation
⚙️AlgorithmIntermediate

Modular Arithmetic Pitfalls

Modular arithmetic is about working with remainders, but programming languages often return negative remainders, so always normalize with (a % MOD + MOD) % MOD.

#modular arithmetic#modular inverse#fermats little theorem+12
∑MathIntermediate

Lucas' Theorem

Lucas' Theorem lets you compute C(n, k) modulo a prime p by working digit-by-digit in base p.

#lucas theorem#binomial coefficient modulo p#prime power modulus+12
∑MathAdvanced

Primitive Roots

A primitive root modulo n is a number g that cycles through all units modulo n when you repeatedly multiply by g, so its multiplicative order equals \(\varphi(n)\).

#primitive root#multiplicative order#euler totient+10
∑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