fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int matrix[2][2] = {
  6. 1, 2, 3, 4
  7. };
  8. printf("%d", matrix[0][0]);
  9. printf("%d", matrix[0][1]);
  10. printf("%d", matrix[1][0]]);
  11. printf("%d", matrix[1][1]);
  12. return 0;
  13. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function ‘int main()’:
prog.cpp:10:27: error: expected ‘)’ before ‘]’ token
  printf("%d", matrix[1][0]]);
        ~                  ^
                           )
stdout
Standard output is empty