process.stdin.setEncoding('utf8');
// 自分の得意な言語で
// Let's チャレンジ！！

var lines = [];
var reader = require('readline').createInterface({
  input: process.stdin,
  output: process.stdout
});
reader.on('line', (line) => {
  lines.push(line);
});
reader.on('close', () => {
  var n = lines[0];
  var as = lines[1].split(' ');
  var result = 0;
  for (a of as) {
    result += 1.0/a;
  }
  result = 1.0/result;
  console.log(result);
})