The absolute()
function returns the absolute value of the number.
-144 => 144
0 => 0
42 => 42
You're overthinking it ;)
Easy steps:
- Number is negative ( < 0)
- We want the absolute value, same value without the sign
- So we remove the minus by applying another minus to it
- Get the absolute value and rule the world