def main(): from collections import Counter, defaultdict import math def prime_numbers(x): if x < 2: return [] prime_numbers = [i for i in range(x)] prime_numbers[1] = 0 for prime_number in prime_numbers: if prime_number > math.sqrt(x): break if prime_number == 0: continue for composite_number in range(2 * prime_number, x, prime_number): prime_numbers[composite_number] = 0 return [prime_number for prime_number in prime_numbers if prime_number != 0] n = int(input()) primes = prime_numbers(n + 1) def soinnsuu(x): s = [] for i in primes: if i > int(math.sqrt(x)): break elif x % i == 0: while x % i == 0: x //= i s.append(i) if not x == 1: s.append(x) return s now = defaultdict(int) p = primes[-1] for i in range(2, n + 1): if i != p: res = dict(Counter(soinnsuu(i))) for k, v in res.items(): now[k] = max(now[k], v) ans = 1 mod = 998244353 for k, v in now.items(): ans *= pow(k, v, mod) ans %= mod print(ans) if __name__ == '__main__': main()