Mojo function
abs
abs(t: IntTuple[origin]) -> IntTuple
Compute the absolute value of each element in an IntTuple
.
This function applies the absolute value operation to each integer
in a potentially nested IntTuple
structure.
Args:
- t (
IntTuple[origin]
): TheIntTuple
to transform.
Returns:
A new IntTuple
with the same structure but with absolute values.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!