#include<stdio.h>
#define gc getchar
typedef long long ll;
inline ll input() {
char c = gc();
while(c<'0' || c>'9') c = gc();
ll ret = 0;
while(c>='0' && c<='9') {
ret = 10 * ret + c - 48;
c = gc();
}
return ret;
}
ll func(ll a,ll b)
{
if(b==0)
return a;
else
return func(b,a%b);
}
int main()
{
ll n,k,i,j,b,count=0,ans=0,cc,t,ar[21];;
n=input();
k=input();
for(i=0;i<k;i++)
ar[i]=input();
t=(1<<k);
for(i=1;i<t;i++)
{
b=1;count=0;
for(j=0;j<k;j++)
{
if(i&(1<<j))
{
b=((b*ar[j])/func(b,ar[j]));
count++;
}
}
if(count%2!=0)
ans=ans+(n/b);
else
ans=ans-(n/b);
}
printf("%lf\n",((double)((double)(n-ans)/n)*100));
return 0;
}
I2luY2x1ZGU8c3RkaW8uaD4KI2RlZmluZSBnYyBnZXRjaGFyCnR5cGVkZWYgbG9uZyBsb25nIGxsOwppbmxpbmUgbGwgaW5wdXQoKSB7CiAgY2hhciBjID0gZ2MoKTsKICB3aGlsZShjPCcwJyB8fCBjPic5JykgYyA9IGdjKCk7CiAgbGwgcmV0ID0gMDsKICB3aGlsZShjPj0nMCcgJiYgYzw9JzknKSB7CiAgICByZXQgPSAxMCAqIHJldCArIGMgLSA0ODsKICAgIGMgPSBnYygpOwogIH0KICByZXR1cm4gcmV0Owp9CmxsIGZ1bmMobGwgYSxsbCBiKQp7CglpZihiPT0wKQoJcmV0dXJuIGE7CgllbHNlCglyZXR1cm4gZnVuYyhiLGElYik7Cn0KaW50IG1haW4oKQp7CglsbCBuLGssaSxqLGIsY291bnQ9MCxhbnM9MCxjYyx0LGFyWzIxXTs7CgluPWlucHV0KCk7CglrPWlucHV0KCk7Cglmb3IoaT0wO2k8aztpKyspCglhcltpXT1pbnB1dCgpOwoJdD0oMTw8ayk7Cglmb3IoaT0xO2k8dDtpKyspCgl7CgkJYj0xO2NvdW50PTA7CgkJZm9yKGo9MDtqPGs7aisrKQoJCXsKCQkJaWYoaSYoMTw8aikpCgkJCXsKCQkJCWI9KChiKmFyW2pdKS9mdW5jKGIsYXJbal0pKTsKCQkJCWNvdW50Kys7CgkJCX0KCQl9CgkJaWYoY291bnQlMiE9MCkKCQlhbnM9YW5zKyhuL2IpOwoJCWVsc2UKCQlhbnM9YW5zLShuL2IpOwoJfQoJcHJpbnRmKCIlbGZcbiIsKChkb3VibGUpKChkb3VibGUpKG4tYW5zKS9uKSoxMDApKTsKCXJldHVybiAwOwoJCn0=