a = int(input()) for i in range(a): n = int(input()) if n == 1: print(10) else: s = '9' + "0" * (n-1) print(s)