FACTDIV  Factorial and divisorss
You have given number of testcases.
Each testcase have two space separated integer L and R. You have to find total value of fun(L)+fun(L+1)+...+fun(R), where fun(x) is total number of positive divisors of x factorial. Since result may be large print it modulo 1000000007.
Input
First line of input contains T total number of testcase.
Next T line contains space separated two integer L and R.
1 <= T <= 1000000
1 <= L <= R <=1000000
Output
For each testcase output the result modulo 1000000007.
Example
Input: 10
1 9
6 7
2 4
7 8
1 3
10 10
3 5
6 7
1 10
6 6 Output: 377
90
14
156
7
270
28
90
647
30
hide comments
nadstratosfer:
20180913 23:44:05
Great problem. Prototyped in PyPy, precalc ran at 1.64s using BACTERIA; same program translated to C couldn't even precompute 50000 in the same time. Went cycling, had some sleep, figured out what needs to be done  C solution speeded up 100+ times and subsequently ACd, yet PyPy now runs at 2.23s. Don't understand the world anymore... 

ashishranjan28:
20170116 16:28:51
any hint..? 

Nishant Gupta:
20160527 08:31:55
Nice one :) 

[Lakshman]:
20160322 16:26:19
what is the expected complexity? 
Added by:  ashish kumar 
Date:  20160317 
Time limit:  1s2.5s 
Source limit:  50000B 
Memory limit:  1536MB 
Cluster:  Cube (Intel G860) 
Languages:  All except: ASM64 GOSU JSMONKEY 
Resource:  self 