from math import * def Sieve(n): lst = [True] * (n + 1) S = set() for i in range(2, ceil(sqrt(n)) + 1): if lst[i]: for j in range(2 * i, n + 1, i): lst[j] = False for i in range(2, n + 1): if lst[i]: S.add(i) return S N = int(input()) mod = 998244353 S = Sieve(N) maxv = max(S) ans = 1 for i in S: if i == maxv: continue val = 1 while val <= N: val *= i val //= i ans *= val ans %= mod print(ans)