Ask Question

Name:
Title:
Your Question:

Answer Question

Name:
Your Answer:
User Submitted Source Code!


Description:
  fibonacci
Language: C/C++
Code:
#include <iostream.h>

int main()
{
   
    int n,i,a=0,b=1,c;
    cout<<"enter the";
    cin>>n;
    cout<<a<<""<<b<<"";
    for(i=0;i<n;i++)
    {
        c=a+b;
        a=b;
        b=c;
        cout<<c<<"";
        return 0;
    
    

    }
}     
Comments: