Skip to content

std/math

import "std/math" as math;
FunctionResult
abs(x: Int) IntAbsolute value
min(a: Int, b: Int) IntSmaller argument
max(a: Int, b: Int) IntLarger argument
sqrt(x: Float64) Float64Square root
floor(x: Float64) Float64Greatest integral value not greater than x
ceil(x: Float64) Float64Smallest integral value not less than x
import "std/math" as math;
fun hypotenuse(a: Float64, b: Float64) Float64 {
return math.sqrt(a * a + b * b);
}