K = int(input())

S = lambda n: sum(map(int,str(n)))

R = lambda n: n/S(n)



arr = []

for i in range(1,1000):

    for j in range(1,15):

        arr.append(int(str(i) + '9'*j))



arr.sort(reverse=True)

min_r = arr[0]

snukes = []

for a in arr:

    r = R(a)

    if r < min_r:

        min_r = r

        snukes.append(a)



for i in range(min(9,K)):

    print(i+1)

if K <= 9:

    exit()

K -= 9



print(*snukes[:-K-1:-1],sep='\n')

K = int(input())

S = lambda n: sum(map(int,str(n)))

R = lambda n: n/S(n)



arr = []

for i in range(1,200):

    for j in range(1,15):

        arr.append(int(str(i) + '9'*j))



arr.sort(reverse=True)

min_r = arr[0]

snukes = []

for a in arr:

    r = R(a)

    if r < min_r:

        min_r = r

        snukes.append(a)



for i in range(min(9,K)):

    print(i+1)

if K <= 9:

    exit()

K -= 9



print(*snukes[:-K-1:-1],sep='\n')

K = int(input())
S = lambda n: sum(map(int, str(n)))
R = lambda n: n / S(n)
arr = []
for i in range(1, 1000):
    for j in range(1, 15):
        arr.append(int(str(i) + "9" * j))
arr.sort(reverse=True)
min_r = arr[0]
snukes = []
for a in arr:
    r = R(a)
    if r < min_r:
        min_r = r
        snukes.append(a)
for i in range(min(9, K)):
    print(i + 1)
if K <= 9:
    exit()
K -= 9
print(*snukes[: -K - 1 : -1], sep="\n")

K = int(input())
S = lambda n: sum(map(int, str(n)))
R = lambda n: n / S(n)
arr = []
for i in range(1, 200):
    for j in range(1, 15):
        arr.append(int(str(i) + "9" * j))
arr.sort(reverse=True)
min_r = arr[0]
snukes = []
for a in arr:
    r = R(a)
    if r < min_r:
        min_r = r
        snukes.append(a)
for i in range(min(9, K)):
    print(i + 1)
if K <= 9:
    exit()
K -= 9
print(*snukes[: -K - 1 : -1], sep="\n")

-for i in range(1, 1000): +for i in range(1, 200):