You are on page 1of 1

#include <iostream>

using namespace std;
using std::cout;
int main()
{
int N, ROWS,k;
k=1;
std::cout<<"enter the no of rows/n";
cin>>N;
ROWS=N;
for(int i=0;i<=ROWS-1;++i)
{
for(int j=0;j<=i;++j)
{
if(j/2!=0)
std::cout<<k*(2*k-1)
k++
}
}
return 0;
}