#include <bits/stdc++.h>
using namespace std;
int main() {
  int k;
  cin >> k;
  int n = 0;
  int count = 0;
  while (count != k) {
    n++;
    int na = 0;
    na = n;
    int sn = 0;
    while (na != 0) {
      sn += na % 10;
      na = na / 10;
    }
    if (n / sn == 1) {
      cout << n << endl;
      count++;
    }
  }
}
