#include <stdio.h>
int main()
{
	double n;
	double x;
	double s;
	scanf("%lf",&n);
	int i; 
	for ( i = 1; i <= n; i++ )
	{
		if ( i % 2 == 1 )
			x++;
	}
	s = x / n;
	printf("%.10f",s);	
	
	return 0; 
}