Gitly
English
Русский
Español
日本語
中文
Português
Log in
Register
v
/
vlib
/
math
/
exp.js.v
12
lines
·
9
sloc
·
193 bytes
·
757929392e0e7a75fc1272116460981e589737d5
Raw
1
module
math
2
3
fn
JS.Math.exp(x f64) f64
4
5
// exp calculates exponent of the number (math.pow(math.E, x)).
6
@[inline]
7
pub
fn
exp(x f64) f64 {
8
mut
res := 0.0
9
#res.val = Math.exp(x)
10
11
return
res
12
}
13