n = eval(input())

print((n/2+n%2)/float(n))
# coding:utf-8

n = eval(input())  # 获取输入数字N



# 根据获取的数据n，进行后续代码的补充

if n % 2 == 0:

    print(0.5)

else:

    print((n+1)*1.0/2/n)



n = eval(input())
print((n / 2 + n % 2) / float(n))

# coding:utf-8
n = eval(input())  # 获取输入数字N
# 根据获取的数据n，进行后续代码的补充
if n % 2 == 0:
    print(0.5)
else:
    print((n + 1) * 1.0 / 2 / n)

-n = eval(input()) -print((n / 2 + n % 2) / float(n)) +# coding:utf-8 +n = eval(input())  # 获取输入数字N +# 根据获取的数据n，进行后续代码的补充 +if n % 2 == 0: +    print(0.5) +else: +    print((n + 1) * 1.0 / 2 / n)