#include #include #include #include #include #include #include #include #include #include #define ALL(obj) (obj).begin(),(obj).end() #define RALL(obj) (obj).rbegin(),(obj).rend() #define P pair #define MOD 1000000007 #define INF 1012345678 #define NINF (-2147483647-1) #define LLINF 9223372036854775807 using ll = long long; using namespace std; //gcd(long long) ll gcd(ll a, ll b) { return b ? gcd(b, a%b) : a; } int main() { int N; cin >> N; cout << gcd(N, N * (N - 1) / 2) << endl; getchar(); getchar(); return 0; }