Created
May 5, 2023 12:49
-
-
Save kbakdev/ac488618e341c6641eb5fa47dceae1b6 to your computer and use it in GitHub Desktop.
Fibonacci Recursive Go
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
func FibonacciRecursive(n int) int { | |
if n <= 1 { | |
return n | |
} | |
return FibonacciRecursive(n-1) + FibonacciRecursive(n-2) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment