#include
using namespace std;
int main(){
int n, t1=0, t2=1,nextterm=1;
cout<<“enter the number of terms:”<<endl;
cin>>n;
cout<<“fibonacci series:”<<endl;
for(int i=1; i<=n; i++)
{
for(int j=0; j<i; j++)
{
cout <<t1 << " ";
nextterm = t1+t2;
t1=t2;
t2=nextterm;
}
cout<<endl;
}
return 0;
}