#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <inttypes.h>
#include <stdint.h>
#include <string.h>
#include <wchar.h>

int main(void) {
	uint64_t K;

	scanf("%"PRIu64, &K);

	uint64_t count = 0;
	while (count < K && count < 8){
		count == K - 1 ? printf("%"PRIu64, (uint64_t)(count + 1)) : printf("%"PRIu64"\n", (uint64_t)(count + 1));

		count++;
	}
	uint32_t adder = 10;
	uint32_t num = 10;
	while (count < K) {
		count == K - 1 ? printf("%"PRIu64, (uint64_t)(num - 1)) : printf("%"PRIu64"\n", (uint64_t)(num - 1));

		num += adder;
		if (num >= adder * 10) {
			adder *= 10;
		}
		count++;
	}

	return 0;
}
