Medium Math > Counting

Problem choosing is an impotent issue for arranging a contest. Now Devskill need to chose an problem for next contest but Devskill's people are very busy and can not chose 1 problem from N problem(s). Now they ask another person to chose k problem from their N problem(s) and they should select 1 problem from them. How many ways a problem can chose in this way. 2 way is different if chosen set from another person is different and/or selected problem for contest is different. You need to find the answer for all k (1 to N) and sum of all is the result for that particular N. Result can be very large, you need to print result module 1000000007. Input: ------ Input starts with an integer **T (1<=T<=100)**, denoting the number of test cases. Each case contains an integer **N (1 ≤ N ≤ 10^18)** denoting the number of problem. Output: ------- For each case of input, output result module 1000000007. Sample Input ------------ 1 2 Sample Output ------------- 4 Explanation -------------- N = 2 Let say problem are 1 and 2. Now, For K = 1, 1. chosen set {1} selected problem {1} 2. chosen set {2} selected problem {2} For K = 2, 1. chosen set {1,2} selected problem {1} 2. chosen set {1,2} selected problem {2} So there are 4 way to selecting a problem.

MD Musfiqur Rahman Sanim