#include <stdio.h>
double jc(int o);
int main (void)
{
    double s,e=1;
    int i,n;
    scanf("%d",&n);
    if(n>=0&&n<=1000){
    for(i=1;i<=n;i++)
    {
        s=jc(i);
        e=e+1.0/s;
    }
    printf ("%.8f",e);}
    return 0;
}
double jc(int o)
{
    int t,result=1;
    for(t=1;t<=o;t++)
        result=result*t;
    return result;
}