n=int(input()) for _ in range(n): x=int(input()) if x==1:print(10) a=10**(x-1)*9 print(a)