Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download

📚 The CoCalc Library - books, templates and other resources

132944 views
License: OTHER
1
fibAkk n n1 n2
2
| (n == 0) = n1
3
| (n == 1) = n2
4
| otherwise = fibAkk (n - 1) n2 (n1 + n2)
5
fib n = fibAkk n 0 1
6
7