/*input
19997
*/

#include <bits/stdc++.h>
 
using namespace std;

#define Fi              first
#define Se              second
#define S(n)            cin >> n
#define P(n)            cout << n
#define pb              push_back
#define pp              pop_back
#define pf              pop_front
#define sp              cout << " "
#define nl              cout << "\n"
#define MIN(con)        (*min_element(ALL(con))) 
#define MAX(con)        (*max_element(ALL(con)))
#define mem(n, a)       memset((n), (a), sizeof(n))
#define ALL(cont)       (cont).begin(),(cont).end()
#define NX(cont)        next_permutation(ALL(cont))
#define PX(cont)        prev_permutation(ALL(cont))
#define F(i, n, r)      for(int i = (n); i < (r); i ++)
#define prec(n)         cout << fixed << setprecision(n)
#define PI              3.14159265358979323846264338327951
#define fast            ios_base:: sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
#define FH(it,c)   for(__typeof((c).begin()) it = (c).begin(); it != (c).end(); ++ it)
 
using ll = long long;
using ss = stringstream;
using ul = unsigned long long;
 
template < typename T > inline T LCM(T a, T b)            { return (a * b) / GCD(a, b); }
template < typename T > inline T GCD(T a, T b)            { ll t; while(a) { t = a; a = b % a; b = t; } return b; }
template < typename T > inline T _max(T a, T b, T c)      { return max( max( a, b ), c ); }
template < typename T > inline T _min(T a, T b, T c)      { return min( min( a, b ), c ); }
template < typename T > inline string toString(T a)       {return to_string(a); }  // Convert int to string
template < typename T > inline void toInt(string s, T &x) { ss str(s); str >> x;}  // Convert string to int

inline void lower(string &s) { 
  FH(it,s) 
    *it = tolower(*it); 
} 
 
inline void upper(string &s) { 
  FH(it,s) 
    *it = toupper(*it); 
}

const ll inf    =  999999999999999999;

bool palin(string s)
{
    string s1 = s;
    reverse(s.begin(), s.end());
    return (s == s1);
} 

ll triangle(ll n)
{
    return (n * (n + 1)) / 2;
}

bool check(ll n) 
{
    if(n == 1) return 0;
    if(n == 2 or n == 3) return 1;
    if(n % 2 == 0 or n % 3 == 0) return 0;

    for(ll i = 5; i * i <= n; i += 6) if(n % i == 0 or n % (i + 2) == 0) return 0;
    return 1;
}

int main ()
{
    fast;
    int n;
    cin >> n;
    set < int > s;
    if(n == 3) {
        s.insert(2);
        s.insert(5);
        s.insert(63);
    }
    else if(n == 4) {
        s.insert(2);
        s.insert(5);
        s.insert(63);
        s.insert(20);
    }
    else if(n == 5) {
        s.insert(2);
        s.insert(5);
        s.insert(63);
        s.insert(20);
        s.insert(30);
    }
    else {
        int k = 0;
        ll sum = 0;
        int o = 0;
        for(int i = 2; k < n and i <= 30000; i ++) {
            if(i % 2 == 0) {
                s.insert(i);
                sum += i;
                k ++;
                o = i;
            }
            else if(i % 3 == 0) {
                s.insert(i);
                sum += i;
                k ++;
                o = i;
            }      
        }
        if(sum % 6 == 2) {
            s.erase(8);
            s.insert(o - (o % 6) + 6);
        }
        else if(sum % 6 == 3) {
            s.erase(9);
            s.insert(o - (o % 6) + 6);
        }
        else if(sum % 6 == 5) {
            //cout << sum << " " << o, nl;
            s.erase(9);
            s.insert(o - (o % 6) + 4);
        }
    }
    for(auto x: s) {
        cout << x, sp;
    }
    
    nl;
    return 0;
}
/*299925005*/


Measured memory_bytes: 1280