def S(str):
    tmp = 0
    for i in range(len(str)):
        tmp += int(str[i])
    return tmp

k = int(input())

count = 1
while k:
    if count*S(str(count+1)) <= (count+1)*S(str(count)):
        print(count)
        k -= 1
    count += 1