Robot

Time Limit: 6000ms
Memory Limit: 65536KB
This problem will be judged on HDU. Original ID: 5673
64-bit integer IO format: %I64d      Java class name: Main

Description

There is a robot on the origin point of an axis.Every second, the robot can move right one unit length or do nothing.If the robot is
on the right of origin point,it can also move left one unit length.A route is a series of movement. How many different routes there are
that after $n$ seconds the robot is still located on the origin point?
The answer may be large. Please output the answer modulo $1,000,000,007$

Input

There are multiple test cases. The first line of input contains an integer $T (1\leq T\leq 100)$ indicating the number of test cases. For each test case:

The only line contains one integer $n(1\leq n \leq 1,000,000)$.

Output

For each test case, output one integer.

Sample Input

3
1
2
4

Sample Output

1
2
9

Source

Language: 
Theme: 
Share Code? 

Powered by NB231 | Current Style: .