k = int(input())
ii = 1
sn = 1

while k != 0:
  target = ii+1
  dig = len(str(target)) 
  sn1_temp=0
  for jj in range(dig)[::-1]:
    sn1_temp += int(target/10**jj) 
    target -= int(target/10**jj) * 10**jj
  sn1 = (ii+1)/sn1_temp
  
  if sn <= sn1:
    print(ii)
    k -=1
    
  sn = sn1
  sn1=0
  ii += 1