what is the output ? Math.floor(-2.1)
a)2
b)-2
c)-3.0
d)0
Answer Posted / 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 |
Post New Answer View All Answers
How would you use Bubble Sort to sort the number of elements?
How do I get 64 bit java?
How will you invoke any external process in java?
Is java hard to learn?
Why does java does not support multiple inheritance? Explain
What is the difference between jfc & wfc?
Explain about features of local inner class?
How many days will it take to learn java?
What do you understand by garbage collection in Java? Can it be forced to run?
Which is faster string or stringbuilder?
What is thread start?
What is tcp and udp?
What is independent and dependent variables in research?
Is array synchronized in java?
What is substring 1 in java?