Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • \$\begingroup\$ You don't need to cast the input to a number; Math.log will do that already: "Each of the following Math object functions applies the ToNumber abstract operator to each of its arguments..." \$\endgroup\$ Commented Jan 4, 2014 at 15:36
  • \$\begingroup\$ Doesn't it suffer from numerical inaccuracies? \$\endgroup\$ Commented Apr 11, 2014 at 6:42
  • \$\begingroup\$ @MarkJeronimus: I actually don't know. It could be, but I haven't yet encountered an incorrect result. \$\endgroup\$ Commented Apr 11, 2014 at 8:41