Home
Posts RSS
Comments RSS
Edit
Programs
Search & Find out
Thursday, November 26, 2009
Fibonacci Series
,
Author:
Raviteja
|
Filed Under:
c
|
To find fibonacci series of 'n' numbers
#include "stdio.h"
#include "conio.h"
void main ()
{
int a,b,c,d,n;
clrscr ();
printf("\n Enter a number : \n");
scanf("%d",&n);
printf ("Answer = 0 1 ");
for (d=0,a=0,b=1;d<(n-2);d++)
{
c=a+b;
printf ("%d ",c);
a=b;
b=c;
}
getch ();
}
Download the executable (.exe) file for this program..
download
0 comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
StoresnOffers.com
Find the best Local Offers, Stores from Stores, Restaurants, Malls and Supermarkets near you. Follow us to get Latest Deals & Offers
http://www.storesnoffers.com
Like Facebook Page
Popular Posts
Labels
c
(57)
c#
(1)
c++
(20)
Blog Archive
Blog Archive
November (1)
December (52)
November (22)
About Me
Raviteja
View my complete profile
My Blog List
Term of Use
0 comments:
Post a Comment