def bb
    n = gets.chomp.to_i
    a = gets.chomp.split(/\s/).map{|x| x.to_i}

    r = 0
    for i in 0..(a.length-1)
        b = Rational(1, a[i])
        r += b
    end

    puts (1/r).to_f
end

bb
