Java Math Library Expression
Consider the following code segment. What is the value of result after the code segment is executed?
double a = 16.0;
double b = -9.0;
double result = Math.sqrt(Math.abs(b)) + Math.pow(a, 0.5);
A
NaN
B
25.0
C
1.0
D
7.0
Question Leaderboard
| Rank | |||||
|---|---|---|---|---|---|
| #1 | kaisuki | 1 | 1 | 0m 00s | 100 |
| #2 | jeonsaw1723 | 1 | 1 | 1m 03s | 37 |
| #3 | y.seong2027 | 1 | 2 | 1m 35s | -5 |
| #4 | richa.tuli | 1 | 2 | 4m 06s | -156 |
| #5 | lsj08030922 | 1 | 1 | 4m 46s | -186 |
APFIVE