G
guille lists
Hi,
sorry if this is a very naive question (I'm new to ruby), but I
haven't found an explication yet. When comparing to floats in ruby I
came across this:
=> 1
I'm a bit lost here, shouldn't (0.1) and (1 - 0.9) be equals regarding
the == operator? I also found that for example 0.3 == (0.2 + 0.1)
returns false, etc.
guille
PD: I'm using ruby 1.8.6 (2008-03-03 patchlevel 114) [universal-darwin9.0]
sorry if this is a very naive question (I'm new to ruby), but I
haven't found an explication yet. When comparing to floats in ruby I
came across this:
=> 1
I'm a bit lost here, shouldn't (0.1) and (1 - 0.9) be equals regarding
the == operator? I also found that for example 0.3 == (0.2 + 0.1)
returns false, etc.
guille
PD: I'm using ruby 1.8.6 (2008-03-03 patchlevel 114) [universal-darwin9.0]