from collections import Counter,defaultdict

import sys,heapq,bisect,math,itertools,string,queue,fractions

mod = 10**9+7

def inp(): return int(sys.stdin.readline())

def inpl(): return list(map(int, sys.stdin.readline().split()))

def inpln(n): return list(int(sys.stdin.readline()) for i in range(n))

def inpl_str(): return list(sys.stdin.readline().split())

def lcm(x, y):

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



n = inp()

t = inpln(n)

tmp = t[0]

for i in range(n-1):

    tmp = lcm(tmp, t[i+1])

print(tmp)

from collections import Counter,defaultdict,deque

from heapq import heappop,heappush,heapify

from bisect import bisect_left,bisect_right 

import sys,math,itertools,fractions,pprint

sys.setrecursionlimit(10**8)

mod = 10**9+7

INF = float('inf')

def inp(): return int(sys.stdin.readline())

def inpl(): return list(map(int, sys.stdin.readline().split()))



n = inp()

a = [inp() for _ in range(n)]

now = a[0]

for i in range(1,n):

    now = a[i]*now//fractions.gcd(a[i],now) 

print(now)
from collections import Counter, defaultdict
import sys, heapq, bisect, math, itertools, string, queue, fractions

mod = 10**9 + 7


def inp():
    return int(sys.stdin.readline())


def inpl():
    return list(map(int, sys.stdin.readline().split()))


def inpln(n):
    return list(int(sys.stdin.readline()) for i in range(n))


def inpl_str():
    return list(sys.stdin.readline().split())


def lcm(x, y):
    return (x * y) // fractions.gcd(x, y)


n = inp()
t = inpln(n)
tmp = t[0]
for i in range(n - 1):
    tmp = lcm(tmp, t[i + 1])
print(tmp)

from collections import Counter, defaultdict, deque
from heapq import heappop, heappush, heapify
from bisect import bisect_left, bisect_right
import sys, math, itertools, fractions, pprint

sys.setrecursionlimit(10**8)
mod = 10**9 + 7
INF = float("inf")


def inp():
    return int(sys.stdin.readline())


def inpl():
    return list(map(int, sys.stdin.readline().split()))


n = inp()
a = [inp() for _ in range(n)]
now = a[0]
for i in range(1, n):
    now = a[i] * now // fractions.gcd(a[i], now)
print(now)

-from collections import Counter, defaultdict -import sys, heapq, bisect, math, itertools, string, queue, fractions +from collections import Counter, defaultdict, deque +from heapq import heappop, heappush, heapify +from bisect import bisect_left, bisect_right +import sys, math, itertools, fractions, pprint +sys.setrecursionlimit(10**8) +INF = float("inf") -def inpln(n): -    return list(int(sys.stdin.readline()) for i in range(n)) - - -def inpl_str(): -    return list(sys.stdin.readline().split()) - - -def lcm(x, y): -    return (x * y) // fractions.gcd(x, y) - - -t = inpln(n) -tmp = t[0] -for i in range(n - 1): -    tmp = lcm(tmp, t[i + 1]) -print(tmp) +a = [inp() for _ in range(n)] +now = a[0] +for i in range(1, n): +    now = a[i] * now // fractions.gcd(a[i], now) +print(now)