DoxigAlpha

abs

Returns the absolute value (modulus) of z.

Function parameters

Parameters

#
z:anytype

Returns the absolute value (modulus) of z.

Functions

#
abs
Returns the absolute value (modulus) of z.

Source

Implementation

#
pub fn abs(z: anytype) @TypeOf(z.re, z.im) {
    return math.hypot(z.re, z.im);
}