matrix

my program crashes upon opening but ill need more help after as im am very lost
#include<iostream>
using namespace std;
int main()
{
int matrix [8][8];
int i,j;
for(int i=0;i<8;++i)
{for (int j=0;j<8;++j)
{ matrix[i][j]=i;
}}
cout<< matrix[i][j];
system ("pause");
return 0;

}
where did i go wrong?
In the statement
cout << matrix[i][j];

What is the value of i and j?
Topic archived. No new replies allowed.