module module1
  
  sub main()
    dim N As integer = Console.Readline
    Dim bunsi As Integer
    
    If N Mod 2 = 0 Then
      bunsi = N/2
    else
      bunsi = (N+1)/2
    end if
    
    console.writeline((bunsi/N).ToString("0.000000000"))
    
  end sub
end module