a matrix code problem

Hi!I'm a beginner in C++ and I have a problem in working with matrix.I need help so could anyone say to me where is the problem?The code is:
#include <iostream>
using namespace std;
int main()
{
int m,n,i,j,t[m][n];
cout<<"m="<<endl;
cin>>m;
cout<<"n="<<endl;
cin>>n;
if(i<j)
t[i][j]=i+j;
cout<<"i="<<i<<endl;
cout<<"j="<<j<<endl;
cout<<"tij="<<t[i,j]<<endl;
j=j+1;
for(j=1;j<=n;j++)
i=i+1;
for (i=1;i<=n;i++)

{

if(i=j);
else
t[i][j]=2*i;
cout<<"i="<<i<<endl;
cout<<"j="<<j<<endl;
cout<<"tij="<<t[i,j]<<endl;
j=j+1;
for(j=1;i<=n;j++)
i=i+1;
for(i=1;i<=n;i++);

}
if(i>j);
else
{
t[i][j]=i*i*i;
cout<<"i="<<i<<endl;
cout<<"j="<<j<<endl;
cout<<"tij="<<t[i,j]<<endl;
j=j+1;
for(j=1;j<=n;i++)
i=i+1;
for(i=1;i<=n;i++);
}
Topic archived. No new replies allowed.