Created
May 7, 2014 18:05
-
-
Save msuchecki/916c949486016e76d22e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def fib(n: Int): Int = { | |
if(n == 0) 0 | |
else if (n == 1) 1 | |
else fib(n-1) + fib(n-2) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment