N = int(eval(input()))

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



rev = 0

for a in As:

    rev += 1/a

print((1/rev))
N = int(eval(input()))

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



cnt = 0

for a in As:

  cnt += 1/a

  

print((1/cnt)) 

 
N = int(eval(input()))
As = list(map(int, input().split()))
rev = 0
for a in As:
    rev += 1 / a
print((1 / rev))

N = int(eval(input()))
As = list(map(int, input().split()))
cnt = 0
for a in As:
    cnt += 1 / a
print((1 / cnt))

-rev = 0 +cnt = 0 -    rev += 1 / a -print((1 / rev)) +    cnt += 1 / a +print((1 / cnt))