Jump to content

Real constants and functions: Difference between revisions

no edit summary
(add bqn)
No edit summary
Line 3,102:
-5
1000</pre>
 
=={{header|V (Vlang)}}==
Many more in math module.
<syntaxhighlight lang="vlang">
import math
 
fn main() {
x := -1.2345
println("e = ${math.e}")
println("pi = ${math.pi}")
println("sqrt(4) = ${math.sqrt(4)}")
println("log(e) = ${math.log(math.e)}")
println("exp(x) = ${math.exp(x)}")
println("abs(x) = ${math.abs(x)}")
println("floor(x) = ${math.floor(x)}")
println("ceil(x) = ${math.ceil(x)}")
println("pow(-x, x) = ${math.pow(-x, x)}")
}
</syntaxhighlight>
 
=={{header|Wren}}==
291

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.