fork download
  1. #include <stdio.h>
  2. #include <iostream>
  3. using namespace std;
  4.  
  5. int main() {
  6.  
  7. int A = {1337, 139, 143, 156}
  8.  
  9. for (int i = 0; i < 4; ++i) {
  10. coutn << *(A + i) << endl;
  11. }
  12.  
  13. return 0;
  14. }
Compilation error #stdin compilation error #stdout 0s 15232KB
stdin
Standard input is empty
compilation info
prog.cpp: In function ‘int main()’:
prog.cpp:7:30: error: scalar object ‘A’ requires one element in initializer
  int A = {1337, 139, 143, 156}
                              ^
prog.cpp:9:2: error: expected ‘,’ or ‘;’ before ‘for’
  for (int i = 0; i < 4; ++i) {
  ^~~
prog.cpp:9:18: error: ‘i’ was not declared in this scope
  for (int i = 0; i < 4; ++i) {
                  ^
stdout
Standard output is empty