#include <bits/stdc++.h>
using namespace std;
const long long INF = numeric_limits<long long int>::max();
const long long MOD = 1000000007;
const long double PI = 3.1415926;
template <class T>
T &chmin(T &a, const T &b) {
  return a = min(a, b);
}
template <class T>
T &chmax(T &a, const T &b) {
  return a = max(a, b);
}
long long int n, m, k, ans = 0, sum = 0, cnt = 0;
string s;
vector<pair<double, long long int> > v;
vector<long long int> va;
long long int d[] = {1,  2,  3,  4,   5,   6,   7,   8,   9,   19,
                     29, 49, 79, 119, 179, 189, 319, 719, 729, 999999};
int main() {
  cin >> k;
  for (long long int i = (long long int)(1); i < (long long int)(10000000);
       i++) {
    ans = 0;
    s = to_string(i);
    for (long long int j = (long long int)(0); j < (long long int)(s.size());
         j++) {
      ans += (s[j] - '0');
    }
    v.push_back({double(i) / ans, i});
  }
  long long int mi = INF;
  for (long long int i = (long long int)(v.size() - 1); i >= 0; i--) {
    if (mi >= v[i].first) {
      mi = v[i].first;
      va.push_back(v[i].second);
    }
  }
  for (long long int i = (long long int)(va.size() - 1); i >= va.size() - k;
       i--) {
    cout << va[i] << endl;
  }
}
