How to print |y-5| in java.lang.math?
Answers
Answered by
2
Answer:
Java Math abs() method with Examples. Last Updated: 10-01-2020. The java.lang.Math.abs() returns the absolute value of a given argument. If the argument is not negative, the argument is returned
Answered by
1
Answer:
Description
The java.lang.Math.abs(int a) returns the absolute value of an int value. If the argument is not negative, the argument is returned. If the argument is negative, the negation of the argument is returned. Note that if the argument is equal to the value of Integer.MIN_VALUE, the most negative representable int value, the result is that same value, which is negative.
Similar questions