13 lines
167 B
Plaintext
13 lines
167 B
Plaintext
|
defn if c t e = {
|
||
|
case c of {
|
||
|
True -> { t }
|
||
|
False -> { e }
|
||
|
}
|
||
|
}
|
||
|
|
||
|
defn fact n = {
|
||
|
if (eq n 0) 1 (n * fact (n - 1))
|
||
|
}
|
||
|
|
||
|
defn main = { fact 6 }
|