Module Basic number theory

Basic number theory

**Frequency: 7/10**

Resources

- [USACO Guide: Divisibility](https://usaco.guide/gold/divisibility?lang=cpp) - [CP Algorithms: Sieve of Eratosthenes](https://cp-algorithms.com/algebra/sieve-of-eratosthenes.html)

Problems

Prime number 2 774 / 822 800
Sieve of Eratosthenes 714 / 736 800
Segmented sieve 447 / 613 800
Prime factors 517 / 593 1000
Maximum GCD 444 / 507 1000
Divisors counting 442 / 471 1000
Largest common divisor 306 / 421 1100
Nearest Element 162 / 225 1200
Divisors counting 2 260 / 381 1200
GCD and LCM 251 / 260 1200
GGCD 200 / 209 1200
Square root sum 105 / 118 1200
Square number 237 / 336 1300
Sum sum sum 22 / 49 1500