mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 01:30:22 +00:00
6 lines
173 B
Plaintext
6 lines
173 B
Plaintext
method ack (m : Number, n : Number) -> Number {
|
|
print "ack {m} {n}"
|
|
if (m < = 0) then {n + 1}
|
|
elseif {n <= 0} then {ack((m -1), 1)}
|
|
else {ack(m -1, ack(m, n-1))}
|
|
} |