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 |
Explain aggregation in java?
What is field name?
How do you sort words in java?
Why we use multi threading instead of multiprocessing?
How many bits is a double?
What is finalize method?
What is maximum size of arraylist in java?
all are saying java doesn't support multiple inheritance but by default Object class is super class for all the user defined classes and we can extend atmost one class so each class can extend more than one class so java supports multiple inheritance?i am confused with this,pls any one explain me.
Mention some interfaces implemented by linked list in java.
What is charat ()?
Write java program to reverse string without using api?
Does any tag exists in HTML to upload and download files ?