FABONACCI SERIES BY LAKSHMAN
#include<conio.h>
#include<stdio.h>
int main(){
printf("Enter any number to know the fabonacci series of that number\n");
int number;
scanf("%d",&number);
int n1=0,n2=1,n3;
print("%d %d",n1,n2);
for(int i=1; i<number; i++){
n3=n1+n2;
print("%d ",n3);
n1=n2;
n2=n3;}
}
Comments
Post a Comment