All submissions for this problem are available.
Rohit is friend with the magical creature from Koi Mil Gaya as we all know, called Jaadu.
Now, Rohit is learning Mathematics from Jaadu; he wants to know about the Mathematics of the other planet, too. In Jaadu's planet, the sequence of powers of two are called the: The JP. (Jaadu power !) That is, 2^1, 2^2, 2^3.... 2^1000000.
10,00,000 being the limit known to the people on Jaadu's planet. Also, Rohit is smart so he notices that this particular sequence starts from index 1 and NOT 0. Now since Rohit thinks that he's understood the sequence well already, so he challenges Jaadu.
Jaadu gives him a number, denoted by N, and asks Rohit to find the number of pairs (i, j) such that (JP [i] - 1) divides (JP[j] - 1) and 1<=i.
Rohit is stunned by this difficult question. And needs your help !
First line contains number of test cases T. Each test cases contains single integer N.
For each test case print total numbers of pairs (i,j) such that 1<=i and JP[i]-1 is divisors of JP[j]-1.
Input: 3 1 2 3 Output: 0 1 2
|Time Limit:||1 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.5, PYPY, CS2, PAS fpc, PAS gpc, RUBY, PHP, GO, NODEJS, HASK, SCALA, D, PERL, FORT, WSPC, ADA, CAML, ICK, BF, ASM, CLPS, PRLG, ICON, SCM qobi, PIKE, ST, NICE, LUA, BASH, NEM, LISP sbcl, LISP clisp, SCM guile, JS, ERL, TCL, PERL6, TEXT, SCM chicken, CLOJ, FS|
Fetching successful submissions
If you are still having problems, see a sample solution here.