A = input()

def calc_sum(target):
    num = str(target)
    a_sum = 0
    for i in num:
        a_sum += int(i)
    return a_sum

def check_num(num):
    if num <= 0:
        return False
    elif (num)/ calc_sum(num) <= (num+1)/calc_sum(num+1):
        return True
    else:
        return False

count = 0
i = 0
while(count < int(A)):
    if check_num(i):
        print(i)
        count +=1
    i += 1
