Chef is good at making pancakes. Generally he gets requests to serve N pancakes at once.
He serves them in the form of a stack.
A pancake can be treated as a circular disk with some radius.
Chef needs to take care that when he places a pancake on the top of the stack the radius of the pancake should not exceed the radius of the largest pancake in the stack by more than 1. 
Additionally all radii should be positive integers, and the bottom most pancake should have its radius as 1.
Chef wants you to find out in how many ways can he create a stack containing N pancakes.
Input
First line of the input contains T (T <= 1000) denoting the number of test cases.
T lines follow each containing a single integer N (1 <= N <= 1000) denoting the size of the required stack.
Output
For each case the output should be a single integer representing the number of ways a stack of size N can be created. As the answer can be large print it modulo 1000000007.
Example
Input
2
1
2

Output
1
2

```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 = 'def bell_numbers(start, stop):\n ## Swap start and stop if start > stop\n if stop < start: start, stop = stop, start\n if start < 1: start = 1\n if stop < 1: stop = 1\n t = [[1]] ## Initialize the triangle as a two\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0-dimensional array\n c = 1 ## Bell numbers count\n while c <= stop:\n  if c >= start:\n   yield t[-1][0] ## Yield the Bell number of the previous \xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0\xa0row\n  row = [t[-1][-1]] ## Initialize a new row\n  for b in t[-1]:\n   row.append(row[-1] + b) ## Populate the new row\n  c += 1 ## We have found another Bell number\n  t.append(row) ## Append the row to the triangle\n\nbe = []\nbe1 = [275408655\n,665183437\n,130342900\n,699431744\n,117550047\n,460234251\n,56770880\n,306091228\n,912949106\n,626369877\n,852501236\n,241076503\n,262988042\n,737247015\n,831044258\n,475123008\n,928949542\n,332750699\n,696284377\n,689111142\n,196862045\n,570365577\n,187156806\n,451528865\n,635110126\n,385331290\n,263486377\n,200189955\n,206842029\n,457862597\n,450522487\n,818984909\n,710634976\n,461356455\n,71985964\n,781500456\n,467334209\n,46762760\n,97663653\n,870671823\n,255977331\n,79650379\n,32876340\n,636190780\n,364339752\n,597149326\n,452604321\n,748186407\n,302032725\n,779013981\n,111971627\n,175687535\n,399961122\n,451853028\n,798326812\n,902775588\n,362836436\n,498862780\n,160000437\n,629259604\n,919729986\n,5994845\n,631476109\n,371320167\n,76164236\n,448643023\n,945220853\n,111192011\n,150577654\n,827274836\n,17668451\n,938388515\n,88566735\n,27940328\n,882026632\n,712756966\n,83642744\n,873585716\n,638987456\n,405271094\n,822216133\n,345587303\n,668558160\n,314983205\n,826678060\n,563583341\n,516998387\n,77703032\n,726563479\n,155257773\n,49705622\n,891556456\n,164127879\n,842558039\n,189099480\n,956148983\n,992226557\n,671472701\n,137476493\n,871069222\n,78241093\n,728497057\n,278888712\n,332713952\n,222597908\n,235198692\n,876216003\n,167364357\n,722341150\n,519365334\n,604855967\n,834816722\n,850786742\n,416385106\n,608404143\n,311628039\n,507077268\n,571796589\n,506398832\n,305540948\n,556971113\n,444565912\n,866477296\n,411983920\n,905854221\n,901986568\n,512703782\n,684027511\n,596294441\n,916862272\n,495347444\n,802477106\n,235968146\n,257527513\n,528476230\n,969655767\n,772044489\n,682345813\n,66418556\n,603372280\n,439233253\n,278244332\n,590581374\n,353687769\n,321352820\n,245676729\n,325255315\n,91010070\n,923699200\n,837616604\n,736177081\n,528261400\n,876353388\n,339195128\n,377206087\n,769944080\n,772953529\n,123785293\n,35984916\n,461119619\n,236140329\n,884137913\n,625494604\n,791773064\n,661436140\n,308509072\n,54134926\n,279367618\n,51918421\n,149844467\n,308119110\n,948074070\n,941738748\n,890320056\n,933243910\n,430364344\n,903312966\n,574904506\n,56353560\n,861112413\n,440392450\n,937276559\n,944662107\n,599470900\n,458887833\n,962614595\n,589151703\n,997944986\n,642961512\n,63773929\n,737273926\n,110546606\n,654813100\n,374632916\n,327432718\n,307869727\n,387738989\n,133844439\n,688886605\n,989252194\n,303514517\n,79062408\n,79381603\n,941446109\n,189307316\n,728764788\n,619946432\n,359845738\n,216171670\n,690964059\n,337106876\n,762119224\n,226624101\n,401879891\n,47069454\n,41411521\n,429556898\n,188042667\n,832342137\n,770962364\n,294422843\n,991268380\n,137519647\n,903275202\n,115040918\n,521250780\n,783585266\n,98267582\n,337193737\n,717487549\n,510794369\n,206729333\n,248526905\n,412652544\n,146948138\n,103954760\n,132289464\n,938042429\n,185735408\n,640754677\n,315573450\n,956487685\n,454822141\n,783819416\n,882547786\n,976850791\n,307258357\n,929434429\n,832158433\n,334518103\n,700273615\n,734048238\n,48618988\n,693477108\n,12561960\n,598093056\n,154072663\n,174314067\n,345548333\n,479759833\n,658594149\n,282072153\n,57970886\n,905112877\n,584117466\n,472359245\n,776860470\n,324216896\n,334199385\n,321245477\n,508188925\n,521442872\n,286692969\n,245141864\n,59342176\n,896413224\n,573301289\n,869453643\n,87399903\n,60102262\n,835514392\n,493582549\n,649986925\n,576899388\n,20454903\n,271374500\n,589229956\n,505139242\n,789538901\n,243337905\n,248443618\n,39334644\n,831631854\n,541659849\n,159802612\n,524090232\n,855135628\n,542520502\n,967119953\n,597294058,\n465231251]\nfor b in bell_numbers(1, 700):\n be.append(b%1000000007);\nt = eval(input())\nt=t-1;\nwhile (t>=0):\n nb = eval(input())\n if nb>=700:\n  print(be1[int(nb)-700])\n else:\n  print(be[int(nb)])\n t=t-1'
_co = compile(_CODE, USER_FILENAME, "exec")
exec(_co, ns, ns)

```

Measured memory_bytes: 95348284