from fractions import gcd

from functools import reduce



n = int(eval(input()))



def lcm_base(x, y):

    return (x * y) // gcd(x, y)



def lcm_list(numbers):

    return reduce(lcm_base, numbers, 1)



t = set()

for _ in range(n):

    t.add(int(eval(input())))



print((lcm_list(t)))
from math import gcd



n = int(eval(input()))

ans = 1

for _ in range(n):

    t = int(eval(input()))

    ans = t * ans // gcd(t, ans)

print(ans)
from fractions import gcd
from functools import reduce

n = int(eval(input()))


def lcm_base(x, y):
    return (x * y) // gcd(x, y)


def lcm_list(numbers):
    return reduce(lcm_base, numbers, 1)


t = set()
for _ in range(n):
    t.add(int(eval(input())))
print((lcm_list(t)))

from math import gcd

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

-from fractions import gcd -from functools import reduce +from math import gcd - - -def lcm_base(x, y): -    return (x * y) // gcd(x, y) - - -def lcm_list(numbers): -    return reduce(lcm_base, numbers, 1) - - -t = set() +ans = 1 -    t.add(int(eval(input()))) -print((lcm_list(t))) +    t = int(eval(input())) +    ans = t * ans // gcd(t, ans) +print(ans)