Skip to content

Behavior of Jruby Math.cbrt(number) does not match MRI #645

@d1egoaz

Description

@d1egoaz

jruby
$ jruby -v

jruby 1.7.3 (1.9.3p385) 2013-02-21 dac429b on Java HotSpot(TM) 64-Bit Server VM 1.7.0_17-b02 [darwin-x86_64]

$ jruby -e "puts Math.cbrt(64)"

3.9999999999999996

ruby
$ ruby -v

ruby 1.9.3p385 (2013-02-06 revision 39114) [x86_64-darwin12.3.0]

$ ruby -e "puts Math.cbrt(64)"

4.0

Math.sqrt behaves the same way as MRI

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions