Prime Factorization

The this post, we introduced how to get all prime numbers from 1 to n in o(nloglogn) time. Base on which, we can do prime factorization in O(logn) time.

Prime Numbers

Prime Numbers in [1, n] The naive method takes O(n^1.5)) time. We could use the famous Sieve of Eratosthenes algorithm.

Divisors & Factors

Summary In this post, I will introduce some common techniques related to divisors and factors.  Details Number of Divisors GCD

Date

Summary In this post, I will introduce some problems related to date.  Details Is Leap Year Days of the Year Days from 1900 Days Between Dates