what is the output ? Math.floor(-2.1)
a)2
b)-2
c)-3.0
d)0
Answers were Sorted based on User's Feedback
Answer / amarnath88888
Math.floor(x) function will return the nearest integer which
is less than the passed value x.
Since -3.0 < -2.1,
-3.0 is the nearest smallest integer.
so answer is c)-3.0
| Is This Answer Correct ? | 28 Yes | 2 No |
Is empty string in java?
Can we modify the throws clause of the superclass method while overriding it in the subclass?
What are the supported platforms by java programming language?
What is the different types of functions?
what are the design patterns in struts?
os is developed in c no java is more secured then c na why dont the os developed is developed using java
Which are the two subclasses under exception class?
Using callable statement how can you pass out parameters, explain with example?
How to sort an array from smallest to largest java?
What is literal example?
What are different type of access modifiers?
Can a class have 2 constructors?