Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. What "is" c#`s Double.NaN?

What "is" c#`s Double.NaN?

Scheduled Pinned Locked Moved C#
csharpquestioncom
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    GerVenson
    wrote on last edited by
    #1

    Well according to the .net Referencesource its:

        public const double NaN = (double)0.0 / (double)0.0;
    

    But how? and Why? and foremost how?

    0 / 0

    should be compiler like ":~" what is this compiler trickery?

    L 1 Reply Last reply
    0
    • G GerVenson

      Well according to the .net Referencesource its:

          public const double NaN = (double)0.0 / (double)0.0;
      

      But how? and Why? and foremost how?

      0 / 0

      should be compiler like ":~" what is this compiler trickery?

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      [fortran - What is the internal representation of inf and NaN? - Stack Overflow](https://stackoverflow.com/questions/640109/what-is-the-internal-representation-of-inf-and-nan) [IEEE Floating-Point Representation | Microsoft Docs](https://docs.microsoft.com/en-us/cpp/build/ieee-floating-point-representation?view=vs-2019)

      It was only in wine that he laid down no limit for himself, but he did not allow himself to be confused by it. ― Confucian Analects: Rules of Confucius about his food

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups