import sys

def input(): return sys.stdin.readline().strip()

def mapint(): return list(map(int, input().split()))

sys.setrecursionlimit(10**9)



N = int(eval(input()))

from math import gcd



ans = 1

for i in range(N):

    t = int(eval(input()))

    g = gcd(ans, t)

    ans = ans*t//g



print(ans)
import sys

def input(): return sys.stdin.readline().strip()

def mapint(): return list(map(int, input().split()))

sys.setrecursionlimit(10**9)



N = int(eval(input()))

from math import gcd

g = 0

ans = 1

for _ in range(N):

    t = int(eval(input()))

    g = gcd(t, ans)

    ans = t*ans//g

print(ans)
import sys


def input():
    return sys.stdin.readline().strip()


def mapint():
    return list(map(int, input().split()))


sys.setrecursionlimit(10**9)
N = int(eval(input()))
from math import gcd

ans = 1
for i in range(N):
    t = int(eval(input()))
    g = gcd(ans, t)
    ans = ans * t // g
print(ans)

import sys


def input():
    return sys.stdin.readline().strip()


def mapint():
    return list(map(int, input().split()))


sys.setrecursionlimit(10**9)
N = int(eval(input()))
from math import gcd

g = 0
ans = 1
for _ in range(N):
    t = int(eval(input()))
    g = gcd(t, ans)
    ans = t * ans // g
print(ans)

+g = 0 -for i in range(N): +for _ in range(N): -    g = gcd(ans, t) -    ans = ans * t // g +    g = gcd(t, ans) +    ans = t * ans // g