#include <bits/stdc++.h>
using namespace std;
int N, vis[10005];
int main () {
#ifndef ONLINE_JUDGE
    freopen("cpp.in", "r", stdin);
#endif
	cin >> N;
	if (N == 3) return puts("6 10 15") & 0;
	for (int i = 6; i <= 10000; i += 6) vis[i] = 1;
	for (int i = 10; i <= 10000; i += 10) vis[i] = 1;
	for (int i = 15; i <= 10000; i += 15) vis[i] = 1;
	for (int i = 1; i <= 10000 && N; i++)
		if (vis[i]) printf("%d ", i), N--;
	putchar('\n');
    return 0;
}
#include <bits/stdc++.h>

using namespace std;

#define ll long long

const int N = 10009;

int n, a[N], tot;

int main() {
    cin >> n;
    for(int i = 6; i < 10000; i ++) {
        if(i == 12) continue;
        if(i % 6 == 0 || i % 10 == 0 || i % 15 == 0)
            a[tot ++] = i;
    }
    for(int i = 0; i < n; i ++) cout << a[i] << ' ';
    return 0;
}
