Buggy python submission (verdict: Runtime Error):
import math as m
from functools import reduce
n,T= int(input()),[]
def f(a, b):
    return int(a * b // m.gcd(a, b))
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//m.gcd(tmp, T[i])*tmp

print(tmp)



Fixed submission:
import math as m
from functools import reduce
n,T= int(input()),[]
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//gcd(tmp, T[i])*tmp

print(tmp)

Buggy python submission (verdict: Runtime Error):
import math as m
from functools import reduce
n,l= int(input()),[]
def f(a, b):
    return int(a * b // m.gcd(a, b))
for i in range(n):
    l.append(int(input()))
print(reduce( lambda x,y: y//m.gcd(x,y)*x, l))





Fixed submission:
import math as m
from functools import reduce
n,T= int(input()),[]
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//gcd(tmp, T[i])*tmp

print(tmp)

Buggy python submission (verdict: Runtime Error):
import math as m
from functools import reduce

n = int(input())
l = []


def f(a, b):
    return int(a * b // m.gcd(a, b))


for i in range(n):
    l.append(int(input()))
print(reduce(f, l))





Fixed submission:
import math as m
from functools import reduce
n,T= int(input()),[]
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//gcd(tmp, T[i])*tmp

print(tmp)

Buggy python submission (verdict: Runtime Error):
import math as m
from functools import reduce

n = int(input())
l = []


def f(a, b):
    return int(a * b / m.gcd(a, b))


for i in range(n):
    l.append(int(input()))
print(reduce(f, l))






Fixed submission:
import math as m
from functools import reduce
n,T= int(input()),[]
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//gcd(tmp, T[i])*tmp

print(tmp)

Buggy python submission (verdict: Runtime Error):
import math as m
from functools import reduce

n=int(input())
l=set([])
def gcd(a,b):
    while a != 0:
        c = a
        a = b % a
        b = c
    return b
def f(a,b):
    return int(a*b/gcd(a,b))
for i in range(n):
    l.add(int(input()))
print(reduce(f,l))

Fixed submission:
import math as m
from functools import reduce
n,T= int(input()),[]
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//gcd(tmp, T[i])*tmp

print(tmp)

Buggy python submission (verdict: Runtime Error):
import math as m
from functools import reduce

n=int(input())
l=set([])
def f(a,b):
    return int(a*b/m.gcd(a,b))
for i in range(n):
    l.add(int(input()))
print(reduce(f,l))










Fixed submission:
import math as m
from functools import reduce
n,T= int(input()),[]
def gcd(a, b):
    while b:
        a, b = b, a % b
    return a
for i in range(n):
    T.append(int(input()))
tmp = max(T)
for i in range(n):
    if tmp % T[i] != 0:
        tmp = T[i]//gcd(tmp, T[i])*tmp

print(tmp)