#include<bits/stdc++.h>
#define ll          long long
#define pb          push_back
#define mp          make_pair
#define pii         pair<int,int>
#define vi          vector<int>
#define all(a)      (a).begin(),(a).end()
#define sz(x)       (int)x.size()
#define hell        1000000007
#define lbnd        lower_bound
#define ubnd        upper_bound
#define bs          binary_search
#define ios         ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
using namespace std;
int a[100005];
int main()
{
	int n;
	cin>>n;

	for(int i=0;i<n;i++)
	cin>>a[i];
	
	if(n==1)
	{
		cout<<a[0];
		return 0;
	}

	long double ans=0;
	int x=0,y=1;
	for(int i=0;i<n;i++)
	{
		y=y*a[i];
		x=__gcd(x,a[i]);
	}

	y=y/x;
	for(int i=0;i<n;i++)
	{
		ans+=(y/a[i]);
	}
	//cout<<ans<<" "<<y<<endl;
	long double z=y*1.0;
	cout<<setprecision(12)<<z/ans;
}