#include <iostream>
#include <fstream>
#include <cmath>
using namespace std;
int main()
{
    int64_t n;
    ifstream fi("DE005.INP");
    fi>>n;
    fi.close();
    ofstream fo("DE005.OUT");
    int64_t a[n];
    if(n<2)
    {
        fo<<-1;
    }
    else
    {
        a[1]=1;
        a[2]=2;
        fo<<2<<' ';
        for (int64_t i=3;i<=n;i++)
        {
            a[i]=a[i-1]+a[i-2];
            if(a[i]<=n)
            {
                int64_t kt=1;
                for (int64_t j=2;j*j<a[i];j++)
                {
                    if(a[i]%j==0)
                    {
                        kt=0;
                        break;
                    }
                }
                if (kt==1)
                {
                    fo<<a[i]<<' ';
                }
            }
            else
            {
                break;
            }
        }
    }
}
