Praveen | Typing Speed Test is a very useful Software available for free Download.

C Programs to Fibonacci Series

      C programming in Fibonacci series means to Add First two numbers is the third number, And Fibonacci series Start zero number. Fibonacci series is 0,1,1,2,3,5,8,..... For example:- (1+1=2), (1+2=3).


Fibonacci series in C programming code

#include<stdio.h>
#include<conio.h>

void main()
{
   int n, a = 0, b = 1, c, i;
   clrscr();
   printf("\n Enter the number of terms ");
   scanf("%d",&n);
   printf("\n First %d terms of fibonacci series are :-",n);
   for ( i = 0 ; i < n ; i++ )
   {
      if ( i <= 1 )
         c = i;
      else
      {
         c = a + b;
         a = b;
         b = c;
      }
      printf(" %d,",c);
   }
   getch();
}


Output:-