import math N = int(input()) r = (N * (N - 1)) // 2 print(math.gcd(N, r))