What will be the output of array variable table after executing the following code?
include<iostream.h>
int main()
{
for(int j=0;j<3;j++)
{
for(int k=0;k<3;k++)
{
if(k==j)
table[j][k]=1;
else table[j][k]=0;
}
}
for(int i=0;i<3;i++)
{
for(int l=0;l<3;l++)
{
cout<<table[i][l] ;
}
cout<<endl;
}
return 0;
}
Reveal answer
Fill a bubble to check yourself