RosettaCodeData/Task/Factorial/Futhark/factorial-1.futhark

4 lines
74 B
Text
Raw Permalink Normal View History

2016-12-05 23:44:36 +01:00
fun fact(n: int): int =
if n == 0 then 1
else n * fact(n-1)