Primorial vs LCM

Given N, divide the least common multiple of 1 to N by the product of all primes up to N and print the quotient modulo 1000000007.

Medium7Number theoryMathNo attempts yetTime limit1sMemory limit256 MB

Problem

You are given an integer NN. Let LCM(1,2,,N)\mathrm{LCM}(1, 2, \ldots, N) be the least common multiple of every integer from 11 to NN, and let P(N)P(N) be the product of every prime that is at most NN.

LCM(1,2,,N)\mathrm{LCM}(1, 2, \ldots, N) is always divisible by P(N)P(N). Print that quotient modulo 10000000071000000007.

For example, with N=5N = 5 we have LCM(1,2,3,4,5)=60\mathrm{LCM}(1, 2, 3, 4, 5) = 60 and P(5)=2×3×5=30P(5) = 2 \times 3 \times 5 = 30, so the quotient is 60/30=260 / 30 = 2.

Input

The first line contains the number of test cases TT. (1T500001 \le T \le 50\,000)

Each of the next TT lines contains one integer NN. (2N10142 \le N \le 10^{14})

Output

For each test case print one line in the format Case x: S, where xx is the test case number starting from 11 and SS is the quotient modulo 10000000071000000007.