let () =
  let n = Scanf.sscanf (input_line stdin) "%d" (fun a -> a) in
  let odds = if n mod 2 = 0 then n / 2 else n / 2 + 1 in
  print_float ((float_of_int odds) /. (float_of_int n));
  print_newline ()