From: "Hal E. Fulton" Date: 2003-08-12T11:26:58+09:00 Subject: Re: NaN and Inifinity ----- Original Message ----- From: "Mike Stok" Newsgroups: comp.lang.ruby To: "ruby-talk ML" Sent: Monday, August 11, 2003 9:21 PM Subject: Re: NaN and Inifinity > In article , > Scott Thompson wrote: > >If I do something like > > > >a = Math::log(-1) > > > >then a properly takes the value NaN. > > > >Is there any way to explicitly assign the variable "a" to NaN (or > >Inifinity or -Infinity) to begin with? I tried finding "NaN" as a > >constant but couldn't locate it. It doesn't appear to be a constant in > >Float or Math. module Math Nan = log(-1) end Now it is. :) Hal