#include <bits/stdc++.h>
using namespace std;
int funcS(int N);
int main() {
  int K;
  cin >> K;
  int i = 1, num = 0;
  while (i <= K) {
    if (funcS(num) == i) {
      i++;
      cout << num << endl;
    }
    num++;
  }
}
int funcS(int N) {
  int keta = 0;
  for (int i = N; i != 0; keta++) {
    i /= 10;
  }
  int num = 0;
  int temN = N;
  int temN2 = N;
  for (int i = keta - 1; i >= 0; i--) {
    temN /= 10;
    num += temN2 - temN * 10;
    temN2 /= 10;
  }
  return num;
}
