fun

ackermann.hs

1
ackermann m n
2
  | m == 0          = n + 1
3
  | m > 0 && n == 0 = ackermann (m-1) 1
4
  | m > 0 && n > 0  = ackermann (m-1) (ackermann m (n-1))
5