|
Authored by: Anonymous on Saturday, April 21 2012 @ 04:32 PM EDT |
its a pity math isn't one of the 37 - as the 'organisation'
of the java libraries maps directly to the old c header
(math.h)
Its also frustrating to see 'creativity' being claimed -
much of the organisation is just logical grouping of
functions.
When people are claiming to spend time on API's its actually
the implementation they're spending the time on - sure the
structure/organisation gets tuned as the implementation
progresses but that's 'business as usual' for development.[ Reply to This | Parent | # ]
|
|
Authored by: Anonymous on Saturday, April 21 2012 @ 05:19 PM EDT |
And that was the essence of Google's reply
> It wouldn't work; existing code wouldn't find it.
[ Reply to This | Parent | # ]
|
|
Authored by: Anonymous on Sunday, April 22 2012 @ 10:22 AM EDT |
The fully qualfiied name is java.lang.Math.sqrt, but you don't have to use the
fully qualified name in your Java program. Either that or Math.sqrt will work,
because everything in the java.lang package is imported automatically into every
Java program.
You're correct that an unqualified sqrt(x) wouldn't invoke Math.sqrt. It would
invoke a sqrt function defined in the current class or a superclass of the
current class, not the one in java.lang.Math.[ Reply to This | Parent | # ]
|
|
|
|
|