const Main = input => {
  input = input.split("\n")

  const n = parseInt(input[0], 10)
  const arr = input[1].split(' ')

  const rec = (memo, i) => {
    if (i === n) return 1 / memo
    return rec(memo + 1 / parseInt(arr[i], 10), i + 1)
  }

  console.log(rec(0, 0))
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"))