 #include <bits/stdc++.h>
#define ll         long long int 
#define pb         push_back
#define umap       unordered_map
#define mod        1000000007
#define all(x)     (x).begin(), (x).end()
#define rall(x)    (x).rbegin(), (x).rend()
#define MN(a,b,c)  min(a,min(b,c))
#define MX(a,b,c)  max(a,max(b,c))
#define pr1         pair<ll,ll>
#define F          first
#define S          second
#define mP         make_pair
#define f(i,n)     for(ll i=0;i<n;i++)
#define f1(i,x,y)  for(ll i=x;i<=y;i++)
#define f2(i,x,y)  for(ll i=x;i>=y;i--)
#define yes        cout<<"YES"<<"\n"
#define no         cout<<"NO"<<"\n"
#define modsum(a,b)  ((a%mod)+(b%mod))%mod
#define modpro(a,b)  ((a%mod)*(b%mod))%mod
#define moddif(a,b)  ((a%mod)-(b%mod)+mod)%mod
//__builtin_popcount(x)
//__builtin_parity(x)   =(number of set bits)%2
//__builtin_clz(x)      to count the number of leading  zeroes 
//__builtin_ctz(x)      to count the number of trailing zeroes 
//__gcd(a,b)
using namespace std;
ll visited[51];
ll Fact(ll x)
{
    ll y=1;
    for(ll i=1;i<=x;i++){y=modpro(y,i);}
    return y;
}
ll dfs(ll parent,vector <ll> v[])
{
    ll y=1;
    visited[parent]=1;
    for(ll i=0;i<v[parent].size();i++)
    {
        if(visited[v[parent][i]]==0)
        {
            y+=dfs(v[parent][i],v);
        }
    }
    return y;
}
ll modularExponentiation(ll x,ll n,ll M)
{
    ll result=1;
    while(n>0)
    {
        if(n % 2 ==1)
            result=((result%M) * (x%M))%M;
        x=((x%M)*(x%M))%M;
        n=n/2;
    }
    return result;
}
ll binaryExponentiation(ll x,ll n)
{
    ll result=1;
    while(n>0)
    {
        if(n % 2 ==1)
            result=result * x;
        x=x*x;
        n=n/2;
    }
    return result;
}
ll pow1(ll x,ll y)
{
    ll z=1;
    while(y--){z=z*x;}
    return z;
}
bool isprime(ll n)
{
    // Corner cases
    if (n <= 1)
        return false;
    if (n <= 3)
        return true;
 
    // This is checked so that we can skip
    // middle five numbers in below loop
    if (n % 2 == 0 || n % 3 == 0)
        return false;
 
    for (int i = 5; i * i <= n; i = i + 6)
        if (n % i == 0 || n % (i + 2) == 0)
            return false;
 
    return true;
}
ll check(ll x)
{
    ll y=1,z=0;
    while(x>y){y*=2;z++;}
    if(x!=y){z--;}
    return z;
}
// Returns n^(-1) mod p 
unsigned long long modInverse(unsigned long long n, int p) 
{ 
    return modularExponentiation(n, p - 2, p); 
} 
  
// Returns nCr % p using Fermat's little 
// theorem. 
unsigned long long nCrModPFermat(unsigned long long n, 
                                 int r, int p) 
{ 
    // Base case 
    if (r == 0) 
        return 1; 
  
    // Fill factorial array so that we 
    // can find all factorial of r, n 
    // and n-r 
    unsigned long long fac[n + 1]; 
    fac[0] = 1; 
    for (int i = 1; i <= n; i++) 
        fac[i] = (fac[i - 1] * i) % p; 
  
    return (fac[n] * modInverse(fac[r], p) % p * modInverse(fac[n - r], p) % p) % p; 
} 
ll modInverse(ll A,ll M)
{
    return modularExponentiation(A,M-2,M);
}
bool cmp(pair<ll,ll> a, pair<ll,ll> b)
{
    if(a.F==b.F)
        return a.S<b.S;
    else 
        return a.F<b.F;
}
int main()
{
 ios_base::sync_with_stdio(false);
    cin.tie(NULL);
   long long int   n;cin>>n;
   long long int ans=2329089562801;
   cout<<ans;
}

 
#include<bits/stdc++.h>
#include<vector>
#include<map>
#include<set>
#include<list>
using namespace std;

#define ll signed long long
#define D double
#define LD long double
#define ff first
#define ss second
#define PII pair<int, int>
#define PLL pair<ll,ll>
#define SPLL pair<sll, sll>
#define pb(x) push_back(x)
#define pp() pop_back()
#define in(x) insert(x)
#define vi vector<int>
#define vll vector<ll>
#define vd vector<double>
#define vs vector<string>
#define vc vector<char>
#define vb vector<bool>
#define vpii vector<PII>
#define vpll vector<PLL>
#define vvi vector<vi>
#define pn(n) cout<<n<<endl
#define pn2(x,y) cout<<x<<" "<<y<<endl
#define pn3(x, y, z) cout<<x<<' '<<y<<' '<<z<<endl;
#define pr(ar) {for (auto i : ar) cout<<i<<" "; cout<<endl;}
#define get(x) cin>>x;
#define get2(x, y) cin>>x>>y;
#define get3(x, y, z) cin>>x>>y>>z;
#define cn(v) for(auto &i : v) cin>>i;
#define sq(a) (a*a)
#define mpii make_pair
#define eps 1e-9
#define MM0(x) memset(x, 0, sizeof x)
#define MM1(x) memset(x, 1, sizeof x)
int dr[] {-1, 0, 1, 0};
int dc[] = {0, 1, 0, -1};
ll const mod = 1e9 + 7;
bool many____testttt = 0;
int const mx = 505;

bool is_prime(int n){
	for(int i = 2; i < n; i++) if(n%i == 0) return 0;
	return 1;
}
void solve()
{
	ll n; cin>>n;
	ll sum = 1;

	vector<vector<int>> div(35);
	for(int i = 2; i <= n; i++){
		int m = i;
		for(int j = 2; j <= i; j++)if(m%j == 0) {
			while(m > 1){
				div[i].pb(j);
				m /= j;
			}
		}
	}
	vi cnt(36, 0);
	//for(auto i : div) pr(i);
	for(auto i : div){
		vi c(35, 0);
		for(auto j : i){
			c[j]++;
		}
		for(int k = 0; k <= 35; k++) cnt[k] = max(cnt[k], c[k]);
	}
	
	for(int i = 2; i <= 35; i++){
		for(int j = 0; j < cnt[i]; j++) sum *= i*1LL;
	}
	cout<<sum+1<<endl;
}
void solve_2() {int t; cin>>t; while(t--) solve();}
 
int main()
{   
  if(!many____testttt) solve();
  else solve_2();
  return 0;
}  