import Text.Printf

main = interact main'
main' = printf "%.10f" . f . read

f :: Integer -> Double
f x = a / b
	where 
    	a = fromIntegral $ length $ filter isOdd [1..x]
    	b = fromIntegral $ length $ [1..x]
        isOdd x = x `mod` 2 == 1