#include <iostream>using namespace std; int p[][] = {1,2,3}; int main() { for(int i = 0 ; i<3;i++) { for(int j = 0 ; j<3;j++) { p[i][j] = 1; } } // your code goes here return 0;}
Standard input is empty
prog.cpp:5:9: error: declaration of ‘p’ as multidimensional array must have bounds for all dimensions except the first int p[][] = {1,2,3}; ^ prog.cpp: In function ‘int main()’: prog.cpp:17:4: error: ‘p’ was not declared in this scope p[i][j] = 1; ^
Standard output is empty
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!