import std.stdio;
import std.string;
import std.conv;
import std.math;
import std.algorithm;

long s_n(long n) {
    int sum = 0;
    while (n != 0) {
        sum += n % 10;
        n /= 10;
    }

    return sum;
}

void main() {
    long k = readln.chomp.to!(long);

    if (k <= 9) {
        for (int i = 1; i <= k; i++) {
            writeln(i);
        }
        return;
    }
    
    for (int i = 1; i <= 9; i++) {
        writeln(i);
    }

    int cnt = 9;
    long i = 10;
    while (cnt < k) {
        string s = i.to!(string);
        if (s[0] == '1') {
            if (i == 19) {
                writeln(i);
                cnt++;
            }
            else {
                if (s.length <= 2) {
                    if (i % 10 == pow(10, s.length - 1) - 1) {
                        writeln(i);
                        cnt++;
                    }
                }
                else {
                    if (s[2..$].to!(long) == pow(10, s.length - 2) - 1) {
                        writeln(i);
                        cnt++;
                    }
                }
            }
        }
        else {
            if (s[1..$].to!(long) == pow(10, s.length - 1) - 1) {
                writeln(i);
                cnt++;
            }
        }
        i++;
    }
}