Tuesday , December 6 2016
Home / C / c program to print fibonacci numbers using recursion

c program to print fibonacci numbers using recursion

Fibonacci numbers using recursion

You must have already come across program to print fibonacci numbers without recursion, Here is given fbonacci number series using recursion.
PROS or New concept used:
1. You DONT have to print 0 and 1 first and run the loop n-2 times.
2. Giving modularity to program since recursion uses function or method thus decreases complexity to understand by a stranger coder.

Concept:

1. TO start with the fibonacci series we first take a=-1 and b=1
thus c= a+b = -1 +1 = 0;

1 1 2 3 5 8 13

a

b

c

a

b

c

a

b

c

a

b

c

2. Then replacing the values of a and b;
a=b and b=c; AS seen from above table.

ALSO CHECK:

OUTPUT:

fibonacci series using recursion
C program for fibonacci series using recursion
Also See:   C program for priority scheduling

Check Also

Hide Mouse Pointer C Program

How to Hide a Mouse Pointer Program in C : This program will show and hide ...

Leave a Reply

Your email address will not be published. Required fields are marked *

Preventing spam * Time limit is exhausted. Please reload the CAPTCHA.