Modules
Using module
use mathputs math.abs(-5) // 5Alias
use m as "math"
use my_math as "this-is-my-custom-math"Creating module
1. By code
2. With C++
Last updated
use mathputs math.abs(-5) // 5use m as "math"
use my_math as "this-is-my-custom-math"Last updated
func add(a, b) {
return a + b
}
return { add }use my_mod = "my-module"
puts my_mod.add(4, 5) // 9$ aup main.aup