P1835 Prime Density
Background
Update:
- 2024.8.12: Added a set of hack testdata.
Description
Given $L,R$, please compute the number of primes in the interval $[L,R]$.
$1\leq L\leq R < 2^{31}$,$R-L\leq 10^6$。
Input Format
The first line contains two positive integers $L$ and $R$.
Output Format
One line containing a single integer, the number of primes in the interval.
Explanation/Hint
Translated by ChatGPT 5