A simple prime calculator. A valid solution to http://www.spoj.com/problems/PRIME1/.
The input begins with the number t of test cases in a single line. In each of the next t lines there are two numbers m and n, separated by a space. The output print, for each test case, all the primes on that interval separated by line breaks.
Input:
2
1 10
3 5
Output:
2
3
5
7
3
5