← Back

Number Theory Basics

Divisibility, primes, gcd, modular arithmetic fundamentals.

mathnumber-theoryUpdated 2025-09-01

gcd

  • Euclid: gcd(a,b)=gcd(b,a%b)

lcm

  • lcm(a,b)=a/gcd(a,b)*b