BETA
School Problem's Submission isn't counted in score!

Submissions: 7137 Accuracy:

11.39%

Sum of all prime numbers between 1 and N.
     

Given a positive integer N, calculate the sum of all prime numbers between 1 and N.

Input:
The first line of input contains an integer T denoting the number of test cases.
The first line of each test case is N.

Output:
Print the sum of all prime numbers between 1 and N.

Constraints:
1 ≤ T ≤ 50
1 ≤ N ≤ 1000000

Example:
Input:
2
5
10

Output:
10
17

** For More Input/Output Examples Use 'Expected Output' option **

Set Default Code

					   
It is recommended to 'Compile & Test' your code before clicking 'Submit'!

Compilation/Execution Result:

Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.