Special Primes

All submissions for this problem are available.
Prime numbers are arranged in a ordered list $U$, in increasing order. Let $S$ be a sublist of $U$ with a unique property that for every element $A$ belonging to list $S$, if $i$ denotes the index of $A$ in list $U$, than $i$ also belongs to list $U$. Given $N$, find sum of first $N$ elements of list $S$, assuming 1based indexing. As the sum can be very large, print the sum modulo $10^{9}+7$. ###Input: The first line of the input contains a single integer $T$ denoting the number of test cases. Only line of each test case has an integer $N$ . ###Output: For each test case, print a single integer denoting the sum of first $N$ elements of set $S$ modulo $10^{9}+7$. ###Constraints  $1 \leq T \leq 10000$  $1 \leq N \leq 1000$ ###Subtasks  20 points :  $1 \leq T \leq 10000$  $1 \leq N \leq 10$  20 points :  $1 \leq T \leq 100$  $1 \leq N \leq 100$  60 points : ***Original Constraints*** ###Sample Input: 2 1 2 ###Sample Output: 3 8 ###EXPLANATION: Example case 1: First few elements of set $S$ are {3,5,11...} , so sum is 3. Example case 2: Sum is 3+5=8.Author:  njha1999 
Tags  njha1999 
Date Added:  3102018 
Time Limit:   0.5 sec 
Source Limit:  50000 Bytes 
Languages:  C, CPP14, JAVA, PYTH, PYTH 3.6, PYPY, PYP3 
Comments
 Please login at the top to post a comment.
SUCCESSFUL SUBMISSIONS
Fetching successful submissions