T, = map(int, input().split()) for _ in range(T): N, = map(int, input().split()) if N!=1: print('9'+'0'*(N-1)) else: print(10)