N = int(input()) for i in range(N): d = int(input()) if d == 1: print(10) continue print(9 * 10 ** (d - 1))