Chef has an array A consisting of N integers (1-based indexing). He asks you to perform the following operation M times:

	for i = 2 to N:
		Ai = Ai + Ai-1

Your task is to find the xth element of the array (i.e., Ax) after performing the above operation M times. As the answer could be large, please output it modulo 109 + 7.

-----Input-----
- The first line of input contains an integer T denoting the number of test cases.
- The first line of each test case contains three space-separated integers — N, x, and M — denoting the size of the array, index of the element you need to find, and the amount of times you need to repeat operation before finding the element, respectively. The second line contains N space-separated integers A1, A2, …, AN.

-----Output-----
For each test case, output a single line containing one integer: Ax modulo 109 + 7. 

-----Constraints-----
- 1 ≤ T ≤ 10
- 1 ≤ x ≤ N ≤ 105
- 1 ≤ M ≤ 1018 
- 1 ≤ Ai  ≤ 1018

-----Subtasks-----Subtask 1 (8 points):
- 1 ≤ x ≤ min{2, N}Subtask 2 (24 points):
- 1 ≤ N * M ≤ 106Subtask 3 (68 points):  No additional constraints

-----Example-----
Input:
2
3 2 3
1 2 3
3 3 3 
1 2 3

Output:
5
15

-----Explanation-----
Values in the array A:
- Before the operations: [1, 2, 3]
- After the first operation: [1, 3, 6]
- After the second operation: [1, 4, 10]
- After the third operation: [1, 5, 15]

Since input file can be fairly large (about 8 MB), it's recommended to use fast I/O (for example, in C++, use scanf/printf instead of cin/cout).

```python

USER_FILENAME = "<user_code>"
import sys, json, builtins
import math, heapq, bisect, itertools, functools, collections, statistics, fractions, decimal, operator, array, random, re, string, os, pathlib
try:
    import resource as _res
except Exception:
    _res = None
from collections import Counter, defaultdict, deque, OrderedDict
from functools import lru_cache, reduce
from itertools import accumulate, permutations, combinations, product
from math import gcd, ceil, floor, sqrt
from decimal import Decimal
try:
    from typing import *
except Exception:
    pass
try:
    sys.setrecursionlimit(1_000_000)
except Exception:
    pass
try:
    import site as _site
    try:
        _sys_sites = _site.getsitepackages() if hasattr(_site, "getsitepackages") else []
        for _p in _sys_sites:
            if _p and _p not in sys.path:
                sys.path.append(_p)
    except Exception:
        pass
    try:
        _usp = _site.getusersitepackages()
        if isinstance(_usp, str):
            _usp = [_usp]
        for _p in _usp:
            if _p and _p not in sys.path:
                sys.path.append(_p)
    except Exception:
        pass
except Exception:
    pass

ns = {"__name__": "__main__"}
for _k, _v in list(globals().items()):
    if not _k.startswith("_"):
        ns[_k] = _v
_CODE = 'T=int(input())\nfor k in range(T):\n n,x,m=list(map(int,input().split()))\n l1=[int(i) for i in input().split()]\n l2,l3=[],[]\n for i in range(len(l1)):\n  l2.append(0)\n  l3.append(0)\n l2[0]=l1[0]%1000000007\n for i in range(1,len(l1)):\n  l2[i]=((l2[i]%1000000007)+(l2[i-1]%1000000007))%1000000007\n if m==1:\n  print(l1[x-1]%1000000007)\n elif m==2:\n  print(l2[x-1])\n else:\n  l3[0]=l2[0]\n  l3[1]=(l1[1]+((m)*l1[0])%1000000007)%1000000007\n  s=0\n  v=0\n  for i in range(2,x):\n   s=l2[i-1]*(l2[i-1]-1)//2\n   v=l3[i-1]*(l3[i-1]+1)//2\n   l3[i]=(v-s)%1000000007\n print(l3[x-1])\n  \n  \n \n'
_co = compile(_CODE, USER_FILENAME, "exec")
exec(_co, ns, ns)

```

Measured memory_bytes: 13677