Last three digits of the integer part

For each n up to 2e9, report the last three digits of the integer part of (3+sqrt(5))^n, zero padded to three digits.

Medium7MathNumber theoryMatrixDivide and conquerNo attempts yetTime limit2sMemory limit512 MB

Problem

Find the last three digits of the integer part of (3+5)n(3+\sqrt{5})^n.

For example, with n=5n = 5, (3+5)5=3935.73982(3+\sqrt{5})^5 = 3935.73982\ldots, so the answer is 935.

If the integer part has fewer than three digits, pad it with leading zeros so the answer always has three digits. For example, with n=2n = 2, (3+5)2=27.4164079(3+\sqrt{5})^2 = 27.4164079\ldots, so the answer is 027.

Input

The first line contains the number of test cases TT (1T1001 \le T \le 100).

Each of the next TT lines contains one natural number nn (2n2×1092 \le n \le 2 \times 10^9).

Output

For each test case, print the answer on one line in the form Case #c: x. Here cc is the test case number, counted from 1, and xx is the answer for that test case. Always write xx with three digits.