~/algor $ cat problems/sonlar-eratosfen-galviri
Sieve of Eratosthenes
Easy
1000 ms
128 MB
29%
You are given a positive integer $n$. Find how many primes there are among the numbers from $1$ to $n$.
Input
One positive integer $n$.
Output
One integer — the number of primes from $1$ to $n$.
Note
$1 \le n \le 5 * 10^{6}$
Examples
Input #1
10
Output #1
4
Input #2
20
Output #2
8