Skip to content

Instantly share code, notes, and snippets.

@vlad-bezden
Created December 6, 2015 13:14
Show Gist options
  • Save vlad-bezden/bbfde9b4567d323e9fbf to your computer and use it in GitHub Desktop.
Save vlad-bezden/bbfde9b4567d323e9fbf to your computer and use it in GitHub Desktop.
Fibonacci implementation in F#
let rec fibonacci n =
match n with
| 1 | 2 -> 1
| _ -> fibonacci (n - 1) + fibonacci (n - 2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment