WoW Lua

Returns the absolue value of the number.

absoluteValue = math.abs(num);
absoluteValue = abs(num);

Arguments[edit | edit source]

num
Number - number to return numeric (absolute) value of.

Returns[edit | edit source]

absoluteValue
Number - The absolute value of the argument number.

Example[edit | edit source]

print(abs(-14)); -- 14
Community content is available under CC-BY-SA unless otherwise noted.