blob: 77c204364951e660f3a2c9e20629cefaa77f58a9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
module math
fn test_factorial() {
assert factorial(12) == 479001600
assert factorial(5) == 120
assert factorial(0) == 1
}
fn test_log_factorial() {
assert log_factorial(12) == log(479001600)
assert log_factorial(5) == log(120)
assert log_factorial(0) == log(1)
}
|