Skip to content

Instantly share code, notes, and snippets.

@icco
Created March 1, 2009 19:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save icco/72453 to your computer and use it in GitHub Desktop.
Save icco/72453 to your computer and use it in GitHub Desktop.
Recursive Fibinocci Sequence in C
void doWork(int a1,int a2,int n)
{
int a3 = 0;
if(n <= 2)
{
return;
}
else
{
a3=a1+a2;
doWork(a2,a3,n-1);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment