Problem:
 Score : 200 points    Problem Statement Given is a sequence of N integers A_1, \ldots, A_N .  Find the (multiplicative) inverse of the sum of the inverses of these numbers, \frac{1}{\frac{1}{A_1} + \ldots + \frac{1}{A_N}} .      Constraints  1 \leq N \leq 100  1 \leq A_i \leq 1000         Input Input is given from Standard Input in the following format:  N  A_1  A_2  \ldots  A_N       Output Print a decimal number (or an integer) representing the value of \frac{1}{\frac{1}{A_1} + \ldots + \frac{1}{A_N}} .  Your output will be judged correct when its absolute or relative error from the judge's output is at most 10^{-5} .        Sample Input 1 2
10 30      Sample Output 1 7.5  \frac{1}{\frac{1}{10} + \frac{1}{30}} = \frac{1}{\frac{4}{30}} = \frac{30}{4} = 7.5 .  Printing 7.50001 , 7.49999 , and so on will also be accepted.       Sample Input 2 3
200 200 200      Sample Output 2 66.66666666666667  \frac{1}{\frac{1}{200} + \frac{1}{200} + \frac{1}{200}} = \frac{1}{\frac{3}{200}} = \frac{200}{3} = 66.6666... .  Printing 6.66666e+1 and so on will also be accepted.       Sample Input 3 1
1000      Sample Output 3 1000  \frac{1}{\frac{1}{1000}} = 1000 .  Printing +1000.0 and so on will also be accepted.

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
B = []
for i in range(N):
    B.append(float(1 / A[i]))

C = float(sum(B))

print(float(1 / C))

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

rev_a = []
for i in range(n):
  rev_a.append(1 / a[i])

print(1 / sum(rev_a))

Solution (Python):
input()
print(1/sum([1/i for i in map(int,input().split())]))

Solution (Python):
input()
*l,=map(int,input().split())
print(1/sum([1/i for i in l]))

Solution (Python):
n = int(input())
A = list(map(int, input().split()))

sum1 = 0
for i in range(n):
    sum1 += 1/A[i]
    
sum = 1 / sum1
print(sum)

Solution (Python):
n=int(input())
li=list(map(int,input().split()))
ans=0
for i in li:
  ans+=1/i
print(1/ans)

Solution (Python):
import math
import collections
import itertools
import heapq

def main():
    N = int(input())
    A = list(map(int, input().split()))

    prod = 1
    for a in A:
        prod *= a
    prod_div_a = [0] * N
    for i in range(N):
        prod_div_a[i] = prod // A[i]
    res = prod / sum(prod_div_a)
    print(res)
    

if __name__ == "__main__":
    main()

Solution (Python):
N=int(input())
An=list(map(int,input().split()))

B=0

for A in An:
    B+=1/A

print(1/B)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
sum_inverse = 0

for i in range(N):
    sum_inverse += 1 / A[i]

print(1 / sum_inverse)

Solution (Python):
import sys
from io import StringIO
import unittest


def resolve():
    
    n = int(input())
    a = list(map(int, input().split()))
    

    print(1 / sum([1/aa for aa in a]))


class TestClass(unittest.TestCase):
    def assertIO(self, input, output):
        stdout, stdin = sys.stdout, sys.stdin
        sys.stdout, sys.stdin = StringIO(), StringIO(input)
        resolve()
        sys.stdout.seek(0)
        out = sys.stdout.read()[:-1]
        sys.stdout, sys.stdin = stdout, stdin
        self.assertEqual(out, output)

    def test_入力例_1(self):
        input = """2
10 30"""
        output = """7.5"""
        self.assertIO(input, output)

    def test_入力例_2(self):
        input = """3
200 200 200"""
        output = """66.66666666666667"""
        self.assertIO(input, output)

    def test_入力例_3(self):
        input = """1
1000"""
        output = """1000"""
        self.assertIO(input, output)


if __name__ == "__main__":
    
    resolve()

Solution (Python):
N=int(input())
A=list(map(int,input().split()))

ans=0
for i in range(N):
  ans+=1/A[i]

print(1/ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
print(1 / sum(list(1 / x for x in A)))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
sum_ = 0
for i in range(n):
    sum_ += 1/a[i]
print(1/sum_)

Solution (Python):
input()
l = list(map(int,input().split()))
s = sum(1/i for i in l)
print(1/s)

Solution (Python):
n = int(input())
b = list(map(int,input().split()))
ans = 0
for i in range(n):
    ans += 1/b[i]
print(1/ans)

Solution (Python):
from functools import reduce
from operator import add, mul

N = int(input())
A = [int(x) for x in input().split()]

numer = reduce(mul, A)
denom = reduce(add, [(numer // A[i]) for i in range(N)])

print(numer / denom)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

sum = 0
for i in range(n):
    sum += 1 / a[i]
print(1/sum)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

print(1 / sum([1 / a_i for a_i in a]))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

p = 1
for i in a:
    p *= i

b = []
for i in a:
    b.append(p//i)
print(p/sum(b))

Solution (Python):
n = int(input())
xs = [int(x) for x in input().split()]

ys = map(lambda x: 1. / x, xs)
print(1. / sum(list(ys)))

Solution (Python):










import sys

def input(): return sys.stdin.readline().rstrip()
def iIn(): return int(input())
def iInM(): return map(int, input().split())
def iInM1(): return map(int1, input().split())
def iInLH(): return list(map(int, input().split()))
def iInLH1(): return list(map(int1, input().split()))
def iInLV(n): return [iIn() for _ in range(n)]
def iInLV1(n): return [iIn()-1 for _ in range(n)]
def iInLD(n): return [iInLH() for _ in range(n)]
def iInLD1(n): return [iInLH1() for _ in range(n)]
def sInLH(): return list(input().split())
def sInLV(n): return [input().rstrip('\n') for _ in range(n)]
def sInLD(n): return [sInLH() for _ in range(n)]

def OutH(lst, deli=' '): print(deli.join(map(str, lst)))
def OutV(lst): print('\n'.join(map(str, lst)))

sys.setrecursionlimit(10 ** 6)

int1 = lambda x: int(x) - 1

INF = int(1e9)
MOD = 1000000007
dx = (-1, 0, 1, 0)
dy = (0, -1, 0, 1)


N = iIn()
A = iInLH()

den = 0
for i in range(N):
    den += 1.0 / A[i]
ans = 1.0 / den
print(ans)

Solution (Python):
def resolve():
    N = int(input())
    A = list(map(int, input().split()))
    print(1/sum(map(lambda x: 1/x, A)))

if '__main__' == __name__:
    resolve()

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
m = [1] * N
for i in range(0,len(A)):
    for j in range(0,len(A)):
        if i == j:
            continue
        else:
            m[i] *= A[j] 
print(m[0]*A[0]/sum(m))

Solution (Python):

N = int(input())
A = list(map(int,input().split()))
ans = 0
for a in A:
    ans += 1/a

print(1/ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
sum_a_r = 0
def reciprocal(x):
  return 1 / x

for i in a:
  sum_a_r += reciprocal(i)
print(reciprocal(sum_a_r))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
t = 0

for i in range(n):
    t += 1 / a[i]

print(1 / t)

Solution (Python):
import sys, math
input = sys.stdin.readline
rs = lambda: input().strip()
ri = lambda: int(input())
rl = lambda: list(map(int, input().split()))
mod = 10**9 + 7

N = ri()
A = rl()

m = 1
for a in A:
	m *= a
s = 0
for a in A:
	s += m/a
print(m/s)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
cnt = 0
for i in range(len(a)):
    cnt += 1/a[i]
print(1/cnt)

Solution (Python):
def main():
    N = input()
    A = map(int, input().split())
    v = sum([1 / a for a in A])
    print(1 / v)


if __name__ == '__main__':
    main()

Solution (Python):
def main():
    n = int(input())
    a = list(map(float, input().split()))
    b = 0
    for i in a:
        b += 1 / i
    print(1 / b)


if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

denom = 0
for i in range(N):
    denom += 1/A[i]

print(1/denom)

Solution (Python):
import sys
import math
import itertools
import collections
import heapq
import re
import numpy as np

rr = lambda: sys.stdin.readline().rstrip()
rs = lambda: sys.stdin.readline().split()
ri = lambda: int(sys.stdin.readline())
rm = lambda: map(int, sys.stdin.readline().split())
rl = lambda: list(map(int, sys.stdin.readline().split()))
inf = float('inf')
mod = 10**9 + 7

_ = ri()
def f(x):
  return 1/int(x)
print(1/sum(map(f, sys.stdin.readline().split())))

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

sm = 0.0
for i in range(N):
    sm += 1/A[i]

print(1/sm)

Solution (Python):
N = int(input())
S = list(map(int, input().split()))
S2 = list(map(lambda x: 1/x, S))
print(1/sum(S2))

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
t = 0
for i in range(n):
    t += 1 / a[i]
print(1 / t)

Solution (Python):
import numpy
n = int(input())
a = numpy.array(list(map(int,input().split())))
print(1/(1/a).sum())

Solution (Python):
a = int(input())
b = list(map(int,input().split()[:a]))
c = 0
for i in range(0, len(b)):
    d = 1/b[i] 
    c += d
e = 1/c
print(e)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
 
from fractions import Fraction
def inverse(f):
    return Fraction(f.denominator,f.numerator)
 
ans = 0
for i in A:
    ans = ans + inverse(i)
 
print(float(inverse(ans)))

Solution (Python):
N = int(input())
print(1/sum([1/a for a in list(map(int,input().split()))]))

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
ans = 0

for a in A:
  ans+=1/a

print(1/ans)

Solution (Python):
import numpy as np
n = int(input())
a = list(map(float, input().split()))
b = sum(np.reciprocal(a))
print(1/b)

Solution (Python):
input();print(1/sum([1/int(i) for i in input().split()]))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
b = 0
for i in range(len(a)):
  b += 1/a[i]
print(1/b)

Solution (Python):
input();print(1/sum([1/i for i in map(int,input().split())]))

Solution (Python):
_,l=open(0)
a=map(lambda x:1/int(x),l.split())
print(1/sum(a))

Solution (Python):
n = int(input())
a = list(map(lambda x:1/int(x),input().split()))
print(1/sum(a))

Solution (Python):
import sys
import math
import itertools
import bisect
from copy import copy
from collections import deque,Counter
from decimal import Decimal
def s(): return input()
def i(): return int(input())
def S(): return input().split()
def I(): return map(int,input().split())
def X(): return list(input())
def L(): return list(input().split())
def l(): return list(map(int,input().split()))
def lcm(a,b): return a*b//math.gcd(a,b)
def gcd(*numbers): reduce(math.gcd, numbers)
sys.setrecursionlimit(10 ** 9)
mod = 10**9+7
count = 0
ans = 0

N = i()
A = l()
for i in A:
    ans += 1/i

ans = 1/ans
print(ans)

Solution (Python):
N = int(input())
A = map(int,input().split())
print(1/sum(1/i for i in A))

Solution (Python):
n = int(input())

a = list(map(int,input().split()))

r = [1/i for i in a]

print(1/sum(r))

Solution (Python):
input();print(1/sum([1/i for i in list(map(int,input().split()))]))

Solution (Python):
n = int(input())
lst = list(map(int, input().split()))
res = 0
for i in range(n):
  res += (1 / lst[i])
print(1 / res)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
s = 0
for i in range(n):
    s += 1 / a[i]
print(1 / s)

Solution (Python):
n = int(input())
an = [int(num) for num in input().split()] 

answer = 0.0
for a in an:
  answer += 1.0/a

answer = 1/answer
print(answer)

Solution (Python):
n = int(input())
A = list(map(int, input().split()))
AA = []
for i in range(n):
    AA.append(1/A[i])

print(1/sum(AA))

Solution (Python):

n, *a = map(int, open(0).read().split())
m = 1
for i in a:
    m *= i
print(m / sum(m // i for i in a))

Solution (Python):
n,*a=map(int,open(0).read().split());print(1/sum([1/x for x in a]))

Solution (Python):
n= int(input())
a = list(map(int, input().split()))
sum1= 0
for i in range(n):sum1 += 1/a[i]
print(1/sum1)

Solution (Python):
import math

N = int(input())
A = list(map(int, input().split()))



num, den = A[0], 0

for i in A:
    num = (num * i) // math.gcd(num, i)

for i in A:
    den += num // i

ans = num / den
print(ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

div = 0
for i in range(N):
  div += 1 / A[i]
  
ans = 1 / div
print(ans)

Solution (Python):
input()
print(1/sum([(1/i)  for i in list(map(int,input().split()))]))

Solution (Python):
import sys
from fractions import Fraction
input = lambda: sys.stdin.readline().rstrip()

def main():
    n = int(input())
    a = list(map(int, input().split()))
    deno = 0
    for i in a:
        deno += Fraction(1, i)
    print(float(1/deno))

if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
print(1/sum([1/int(x) for x in input().split()]))

Solution (Python):
import sys
import heapq
import math
import fractions
import bisect
import itertools
from collections import Counter
from collections import deque
from operator import itemgetter
def input(): return sys.stdin.readline().strip()
def mp(): return map(int,input().split())
def lmp(): return list(map(int,input().split()))

n=int(input())
a=lmp()
ans=0
for i in a:
    ans+=1/i
print(1/ans)

Solution (Python):
N = int(input())
print(1/sum([1/int(x) for x in input().split()]))

Solution (Python):
import sys

def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))  

N = I()
A = LI()

a = 0
for i in range(N):
    a += 1/A[i]

print(1/a)

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
c=0
for i in range(n):
  c+=1/a[i]
print(1/c)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

total1 = 0
total2 = 1
for i in range(N):
  total2 *= A[i]
for i in range(N):
  total1 += total2/A[i]
print(total2/total1)

Solution (Python):
N = int(input())
A = list(map(float,input().split()))
ans = 0
for i in A:
    ans+=1/i
print(1/ans)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
lst = []

for i in range(N):
    x = 1 / A[i]
    lst.append(x)

print(1/sum(lst))

Solution (Python):
n=int(input())
ans=list(map(int,input().split()))
ansr=[1/i for i in ans]
print(1/sum(ansr))

Solution (Python):
N=int(input())
number=list(map(int,input().split()))
number_reverse=[1/i for i in number]
print(1/sum(number_reverse))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
ans = 0
for i in range (n):
  ans += 1/a[i]
print(1/ans)

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
a=map(lambda x:x**(-1),a)
ans=1/(sum(a))
print(ans)

Solution (Python):
def main():
    n = map(int, input().split())
    inlis = list(map(int, input().split()))

    tmp = 0
    for i in range(len(inlis)):
        tmp += 1/inlis[i]
    print(1/tmp)
    
    
if __name__ == "__main__":
    main()

Solution (Python):
N=int(input())
A=list(map(int,input().split()))

product=1
div=0

for i in range(N):
    product*=A[i]
for j in range(N):
    div+=product/A[j]

print(product/div)

Solution (Python):
n=int(input())
a=list(map(int,input().split()))

a1=[]
for i in range(n):
    a1.append(1/a[i])

print(1/sum(a1))

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
lst=[]
for i in range(N):
    x = 1 / A[i]
    lst.append(x)

print(1/sum(lst))

Solution (Python):
n=int(input())
List=list(map(int,input().split()))
add=0
for i in List:
    add+=1/i
print(1/add)

Solution (Python):
from decimal import Decimal
n=int(input())
List=list(map(int,input().split()))
add=0
for i in List:
    add+=Decimal(1/i)
print(Decimal(1/add))

Solution (Python):
import sys

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007


def main():
    N, *A = map(int, read().split())

    p = 1
    for a in A:
        p *= a

    denom = 0
    for a in A:
        denom += p // a

    print(p / denom)
    return


if __name__ == '__main__':
    main()

Solution (Python):

def main():
    _ = int(input())
    a = list(map(int, input().split()))
    t = 0

    for i in a:
        t += 1/i
    print(1/t)
    

if __name__ ==  "__main__":
    main()

Solution (Python):
from decimal import Decimal
N = int(input())
A = list(map(Decimal, input().split()))

ans = 0
for a in A:
  ans += Decimal(1) / a
print(float(Decimal(1) / ans))

Solution (Python):
def main():
    N = int(input())  
    A = list(map(int, input().split()))
    gyaku = 0
    for a in A:
        gyaku += 1/a
    print(1/gyaku)


if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

sum_a = 0

for i in range(n):
  sum_a += 1 / a[i]
print(1 / sum_a)

Solution (Python):
num = int(input())
r = [1/int(i) for i in input().split()]
print(1/sum(r))

Solution (Python):
N=int(input())
A =list(map(int,input().split()))
sum_num=0
for i in range(N):
    sum_num += 1/A[i]
print(1/sum_num)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

ans = 0
for i in A:
  ans += 1./i
print(1./ans)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))

sum = 0
for i in range(n):
    sum += 1 / a[i]

print(1 / sum)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
from decimal import Decimal as dec
s = 0
for i in range(n):
    s += dec(1 / a[i])
print(dec(1 / s))

Solution (Python):
n = int(input())
arr = list(map(int, input().split()))
term = 0
for i in arr:
  term += 1/i
  
print(1/term)

Solution (Python):
import math
from functools import reduce
def lcm_base(x, y):
    return (x * y) // math.gcd(x, y)
def lcm_list(numbers):
    return reduce(lcm_base, numbers, 1)
a=int(input())
b=list(map(int,input().split()))
n=lcm_list(b)
m=0
for i in b:
    m+=n//i
print(n/m)

Solution (Python):
n = int(input())
a = list(map(lambda x :int(x)**(-1),input().split()))

print(sum(a)**(-1))

Solution (Python):
N=int(input())
list=list(map(float, input().split()))
c=0
for i in list:
    list[c]=1/(list[c])
    c+=1
ans=1/(sum(list))
print(ans)

Solution (Python):
n = int(input())
a = [1/int(i) for i in input().split()]
print(1/sum(a))

Solution (Python):
n = int(input())
res = list(map(int, input().split()))
ans = 0 
for x in res:
  ans += 1/x
print(1/ans)

Solution (Python):


def inverse(y):
    return (1/y)

n = int(input())
a = list(map(int, input().split()))
sum = 0

for i in range(n):
    sum += inverse(a[i])
print(inverse(sum))

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
print(1 / sum([1 / a for a in A]))

Solution (Python):
from fractions import Fraction as frac
input()
a = list(map(int,input().split()))
sm = frac("1/" + str(a[0]))
for i in range(1,len(a)):
    sm += frac("1/" + str(a[i]))
print(sm.denominator / sm.numerator)

Solution (Python):
a = int(input())
b = list(map(int, input().split()))
j = [1 / i for i in b]
print(1 / sum(j))

Solution (Python):
N=int(input())
S=0
A=list(map(int,input().split()))
for i in A:S+=1/i
print(1/S)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
ans = 0
for i in range(N):
    ans += 1 / A[i]
ans = 1 / ans
print(ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
den = 0
aseki = 1
for i in range(n):
    for j in range(n):
        if i != j:
            aseki *= a[j]
    den += aseki
    aseki = 1
fra = 1
for i in range(n):
    fra *=a[i]
print(fra/den)

Solution (Python):
a1=int(input())
a2=input()
res1=[i for i in a2.split()]
res=[i for i in a2.split()]
for x in res:
    if int(x)<1 or int(x)>1000:
        res.remove(x)
empty=0
sum_all=0
if 1<=a1<=100:
    if len(res1)==len(res):
        for x in res:
            empty=sum_all
            sum_all=empty+(1/int(x))
        print((1/sum_all))

Solution (Python):
n = int(input())
a = [1/int(i) for i in input().split()]

print(1/sum(a))

Solution (Python):
import sys

def solve():
    input = sys.stdin.readline
    N = int(input())
    A = [int(a) for a in input().split()]
    ans = 0
    for a in A:
        ans += 1/a
    print(1/ans) 

    return 0

if __name__ == "__main__":
    solve()

Solution (Python):
def inpl(): return list(map(int, input().split()))
N = int(input())
print((1 / sum([1/a for a in inpl()])))

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

v = 0.0
for i in a:
    
    v += 1.0 / i

print(1.0 / v)

Solution (Python):
import statistics
n = int(input())
print(statistics.harmonic_mean(map(int, input().split())) / n)

Solution (Python):
def main():
    n = int(input())
    a = list(map(int,input().split()))
    sum = 0
    for i in a:
        sum += 1/i
    print(1/sum)
    
if __name__ == '__main__':
    main()

Solution (Python):
def resolve():
    N = int(input().strip())
    array = list(map(int, input().strip().split(' ')))
    rev_sum = 0
    for i in range(N):
        rev_sum = rev_sum + (1/array[i])
    ans = 1/rev_sum
    print(ans)
resolve()

Solution (Python):
n  = int(input())
a = list(map(int, input().split()))

ans = 0

for i in a:
    ans += 1/i

print(1/ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
v = 0.0
for i in a:
    v += 1.0 / i
print(1.0 / v)

Solution (Python):
def main():
    n = int(input())
    a = list(map(int, input().split()))
    c = 0
    for i in range(n):
        c += 1/a[i]
    print(1/c)

if __name__ == '__main__':
    main()

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
bunsi=1
for i in range(n):
  bunsi*=a[i]

bunbo=0
for i in range(n):
  bunbo += bunsi // a[i]
  
print(bunsi/bunbo)

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
x=0
for i in A:
  x+=1/i
print(1/x)

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
sum = 0
for i in range(N):
  sum += 1/A[i]
print(1/sum)

Solution (Python):
n = input()
a = list(map(int, input().split()))
b = 0
for i in a:
    b += i ** (-1)
print(b ** (-1))

Solution (Python):
import numpy as np
def solve():
    n = int(input())
    a = list(map(int, input().split()))
    tmp = 0
    for i in a:
        tmp += 1/i
    print(1/tmp)

if __name__ == '__main__':
    solve()

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
S = 0
for i in range(N):
    S += 1/A[i]
print(1/S)

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
a=[]
for i in range(n):
    a.append(1/l[i])
print(1/sum(a))

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
ans=0.0
for i in range(n):
    ans+=1/a[i]

print(1/ans)

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
gyaku = 0
for i in A:
    gyaku += 1/i
print(1/gyaku)

Solution (Python):
from fractions import Fraction
n=int(input())
a=[int(i) for i in input().split()]
def frac(n):
  return Fraction(1,n)
b=map(frac,a)
c=Fraction(1,sum(b))
print(float(c))

Solution (Python):
n=int(input())
l = list(map(int,input().split()))
a=1
for i in l:
    a=a*i
b=0
for i in l:
    b+=a/i
print(a/b)

Solution (Python):
n = int(input())
a = list(map(int, input().split()))
res = 1 / sum(map(lambda x: 1 / x, a))
print(res)

Solution (Python):
n = int(input())
a = [int(k) for k in input().split()]
ans = 0
for i in a:
  ans += 1/i
print(1/ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
b = 0
for i in a:
    b = b + 1 / i

print(1 / b)

Solution (Python):
N=int(input())
L=list(map(int,input().split()))
for i in range(N):
  L[i]=1/L[i]
print(1/sum(L))

Solution (Python):
N = map(int, input().split())
A = list(map(int, input().split()))
reverse = 0

for a in A:
    reverse += 1 / a

print(reverse**-1)

Solution (Python):
n=input();print(1/sum(1/int(i) for i in input().split()))

Solution (Python):
n=int(input())
print(1/sum(1/int(i) for i in input().split()))

Solution (Python):
N = int(input())
LA = list(map(int, input().split()))

ans = 0

for i in range(N):
    ans += 1 / LA[i]

fans = 1 / ans

print(fans)

Solution (Python):

import sys


buff_readline = sys.stdin.readline
readline = sys.stdin.readline

INF = 2**62-1


def read_int():
    return int(buff_readline())


def read_int_n():
    return list(map(int, buff_readline().split()))


def read_float():
    return float(buff_readline())


def read_float_n():
    return list(map(float, buff_readline().split()))


def read_str():
    return readline().strip()


def read_str_n():
    return readline().strip().split()


def error_print(*args):
    print(*args, file=sys.stderr)


def mt(f):
    import time

    def wrap(*args, **kwargs):
        s = time.time()
        ret = f(*args, **kwargs)
        e = time.time()

        error_print(e - s, 'sec')
        return ret

    return wrap


class Mod:
    def __init__(self, m):
        self.m = m

    def add(self, a, b):
        return (a + b) % self.m

    def sub(self, a, b):
        return (a - b) % self.m

    def mul(self, a, b):
        return ((a % self.m) * (b % self.m)) % self.m

    def div(self, a, b):
        return self.mul(a, pow(b, self.m-2, self.m))

    def pow(self, a, b):
        return pow(a, b, self.m)


@mt
def slv(M, A):
    from fractions import Fraction
    d = Fraction(0)
    for a in A:
        d += Fraction(1, a)

    return float(1 / d)





def main():
    N = read_int()
    A = read_int_n()
    print(slv(N, A))


if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
A = list(map(int, input().split()))
x=0
for i in A:
    x+=1/i
print(1/x)

Solution (Python):
n=int(input())
alist=list(map(int,input().split()))

sum=0
for a in alist:
    sum += 1 / a
print(1 / sum)

Solution (Python):
N = int(input())
A = list(map(int,input().split()))
B = 0

for i in range(N):
    B += 1/A[i]

print(1/B)

Solution (Python):
import sys
from collections import defaultdict
readline = sys.stdin.buffer.readline



def geta(fn=lambda s: s.decode()):
    return map(fn, readline().split())


def gete(fn=lambda s: s.decode()):
    return fn(readline().rstrip())


def main():
    N = gete(int)
    A = tuple(geta(int))

    ans = sum([1 / ai for ai in A])

    print(1 / ans)


if __name__ == "__main__":
    main()

Solution (Python):
from fractions import Fraction
N = int(input())
a = list(map(int, input().split()))
total = 0
for i in a:
    total += Fraction(1, i)
print(float(Fraction(1, total)))

Solution (Python):
from fractions import Fraction
N = int(input())
A = [int(i) for i in input().split()]
print(float(1 / sum([Fraction(1, a) for a in A])))

Solution (Python):
from functools import reduce
from operator import mul
N = int(input())
A = [int(i) for i in input().split()]

prod = reduce(mul, A)
numerator = prod
denominator = sum([prod // a for a in A])
print(numerator / denominator)

Solution (Python):
import numpy as np
n=int(input())
a=np.array(list(map(int,input().split())))


answer=np.sum(1/a)
print(1/answer)

Solution (Python):
import numpy as np

N = int(input())
A = np.array(list(map(int, input().split())))

answer = np.sum(1/A)
print(1/answer)

Solution (Python):
from decimal import Decimal
import sys


def input(): return sys.stdin.readline().strip()
def I(): return int(input())
def LI(): return list(map(int, input().split()))
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def S(): return input()
def LS(): return input().split()


n = I()
a = LI()

bunbo = sum([Decimal(str(1 / i)) for i in a])
ans = Decimal(str(1 / bunbo))
print(float(ans))

Solution (Python):
N = int(input())
print(1/sum([1/int(a) for a in input().split()]))

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
ans=0
for i in range(0,len(a)):
    ans=ans+(1/a[i])
print(1/ans)

Solution (Python):
n=int(input())
a=list(map(int,input().split()))
p=0
for _ in range(n):
    p+=(1/a[_])
print("{:.6f}".format(1/p));

Solution (Python):
import math
from collections import defaultdict
ml=lambda:map(int,input().split())
ll=lambda:list(map(int,input().split()))
ii=lambda:int(input())
ip=lambda:(input())

"""========main code==============="""
a=ii()
n=ll()
ans=0
for i in n:
    ans+=1/i
print(1/ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

ans = 0
for ai in a:
  ans += (1 / ai)

print(1/ans)

Solution (Python):
n=int(input())
a=[int(i) for i in input().split()]
ans=0.0
d=0
for i in a:
    d=1/i
    ans+=d
print(1/ans)

Solution (Python):
def main():
    n = int(input())
    a = list(map(int, input().split()))
    denom = 0
    for i in a:
        denom += (1 / i)
    print(1 / denom)
main()

Solution (Python):
N=int(input())
A=list(map(int,input().split()))
u=1
d=0
for i in range(N):
  u*=A[i]
for i in range(N):
  d+=u/A[i]
print(u/d)

Solution (Python):
n = int(input())

a = map(int,input().split())
ans = 0
for i in a:
    ans += 1/i
print(1 / ans)

Solution (Python):
N = int(input())
A = list(map(int ,input().split()))
ans = 0

for i in range(N) : 
    B = 1 / A[i]
    ans += B

print(1/ans)

Solution (Python):
_ = int(input())
l = map(int, input().split())
t = 0
for i in l:
    t += 1/i
print(1/t)

Solution (Python):
_ = int(input())
l = map(int, input().split())
t = 0
for i in l:
    t += 1/i
print(1/t)

Solution (Python):
N = int(input())
A = map(int, input().split())
print('{:.16g}'.format(1 / sum(1 / x for x in A)))

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

b = 1
for a in A:
    b *= a

C = [1 for _ in range(N)]
for i, a in enumerate(A):
    C[i] = b//a

print(b/sum(C))

Solution (Python):
N = int(input())
A  = list(map(int, input().split()))
for i in range(len(A)):
  A[i] = 1/A[i]
print(1/sum(A))

Solution (Python):
a = int(input())
A = [int(x) for x in input().split()]
s = sum(1 / a for a in A)
print("{:.015f}".format(1 / s))

Solution (Python):
import numpy as np
n=int(input())
a=np.array(list(map(int,input().split())))
bunnbo=np.sum(1/a)
print(1/bunnbo)

Solution (Python):
def main() -> None:
    _ = int(input())
    A = [int(x) for x in input().split()]
    s = sum(1 / a for a in A)
    print("{:.015f}".format(1 / s))


if __name__ == '__main__':
    main()

Solution (Python):

from collections import deque, defaultdict
from itertools import combinations, combinations_with_replacement
import bisect
from math import factorial, sqrt, log, ceil, floor


def main():
    
    

    N = int(input())
    As = list(map(int, input().split()))

    allprod = 1
    for A in As:
        allprod *= A

    total = 0
    for A in As:
        total += allprod / A

    print(allprod / total)


if __name__ == '__main__':
    main()

Solution (Python):

from collections import deque, defaultdict
from itertools import combinations, combinations_with_replacement
import bisect
from math import factorial, sqrt, log, ceil, floor


def main():
    
    

    N = int(input())
    As = list(map(int, input().split()))

    allprod = 1
    for A in As:
        allprod *= A
    
    total = 0
    for A in As:
        total += allprod / A

    print(allprod / total)


if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

c = 0
for i in range(n):
    c += 1/a[i]

print(1/c)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))

ans = 0
for i in range(n):
  ans += 1/a[i]
print(1/ans)

Solution (Python):
n = int(input())
a = list(map(int,input().split()))
ans = 0
for i in a:
    ans += (i**-1)
print(1/ans)

Solution (Python):
n=int(input())
l=list(map(int,input().split()))
s=0
for i in l:
  s+=1/i
print(1/s)

Solution (Python):
N = int(input())
A = list(map(int, input().split()))

from fractions import Fraction
def inverse(f):
    return Fraction(f.denominator,f.numerator)

ans = 0
for i in A:
    ans = ans + inverse(i)

print(float(inverse(ans)))

Solution (Python):
n=int(input())
a=list(map(int,input().split()))

s=1
for i in a:
  s*=i
ans=s/sum(s/i for i in a)
print(ans)

Solution (Python):
n = int(input())
nums = list(map(float, input().split(" ")))
res = 0
for i in range(n):
    res += (1/nums[i])
print(1/res)

Solution (Python):
input()
print(1.0 / sum(1.0 / float(x) for x in input().split()))