Why are the methods of the Math class are static?
Answer / ranganathkini
The Math class contains methods used for most general
purpose mathematical calculations and hence serve more like
utility methods used for mathematical calculations and do
not depend on instance data to perform their job. Hence they
are static.
Is This Answer Correct ? | 14 Yes | 4 No |
Which collections are thread safe in java?
What restrictions are placed on method overloading and method overriding?
class A{ some variables; public void a()throws Excepion1,Exception2{....} } class B extends A{ variables... public void a()throws E2,E3{.....} } Qns: here override of methods occurs or not,ore else wil give any compilation error or run properly..plz tell me briefly whts happening with the above codes....
Can a constructor have different name than a class name in java?
What is a double?
What is a conditional statement explain with example?
What is hashing principle in java?
What is a variable declaration?
Difference between doublesummarystatistics, intsummarystatistics and longsummarystatistics ?
What we have to do, when we don't want to implement all methods of an interface?
What are the disadvantages of object oriented programming?
Can a double value be cast to a byte?