method
abs
abs()
public
Returns the absolute value of num.
12.abs #=> 12 (-34.56).abs #=> 34.56 -34.56.abs #=> 34.56
Numeric#magnitude is an alias of Numeric#abs.
abs()
public
Returns the absolute value of num.
12.abs #=> 12 (-34.56).abs #=> 34.56 -34.56.abs #=> 34.56
Numeric#magnitude is an alias of Numeric#abs.