Răspuns:
#include <iostream>
using namespace std;
int main()
{
unsigned int a[20][20],i,j,m,n,b=1;
cin>>n>>m;
for(i=1;i<=n;i++)
for(j=1;j<=m;j++)
{
a[i][j]=b*b;
b+=2;
}
for(i=1;i<=n;i++){
for(j=1;j<=m;j++)
cout<<a[i][j]<<" ";
cout<<endl;
}
return 0;
}
Explicație: