#include <bits/stdc++.h>
using namespace std;
const int inf = 0x3f3f3f3f, INF = 0x7fffffff;
const long long infll = 0x3f3f3f3f3f3f3f3fll, INFll = 0x7fffffffffffffffll;
int read() {
  int tmp = 0, fh = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') fh = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    tmp = tmp * 10 + ch - '0';
    ch = getchar();
  }
  return tmp * fh;
}
long long ow10[20], sum[20];
int n;
struct Num {
  long long num;
};
bool operator<(Num x, Num y) {
  long long tmpx = x.num, tmpy = y.num, numx = 0, numy = 0;
  while (tmpx > 0) {
    numx += tmpx % 10;
    tmpx /= 10;
  }
  while (tmpy > 0) {
    numy += tmpy % 10;
    tmpy /= 10;
  }
  long long deata = x.num * numy - y.num * numx;
  return deata > 0 || (deata == 0 && x.num > y.num);
}
priority_queue<Num> hp;
int main() {
  n = read();
  for (int i = 1; i <= 9; i++) hp.push((Num){i});
  ow10[0] = 1;
  for (int i = 1; i <= 18; i++) ow10[i] = ow10[i - 1] * 10;
  long long now = 0;
  while (n) {
    long long tmp = hp.top().num;
    hp.pop();
    if (tmp <= now) continue;
    printf("%lld\n", tmp);
    n--;
    now = tmp;
    int len = 0;
    while (tmp > 0) {
      sum[++len] = tmp % 10;
      tmp /= 10;
    }
    for (int i = 1; i <= 18; i++)
      if (sum[i] != 9) {
        sum[i]++;
        long long nex = 0;
        for (int j = 1; j <= len; j++) nex = nex + sum[j] * ow10[j - 1];
        if (i > len) nex = nex + ow10[i - 1];
        hp.push((Num){nex});
        sum[i]--;
      }
  }
  return 0;
}
