Hello!
Can i use a for() loop this way or should i use two for() loop?
It compiles, executes but nothing gets printed out.
Code:#include <iostream> using namespace std; int main(){ char board[2][33]; for(int i = 0, j = 0; board[i][j] < '\n'; i++,j++){ char board[2][33] ={{0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0}}; if(i<33) cout << board[i][j]; else cout << endl; } //system("pause"); return 0; }