fork(1) download
  1. #include <iostream>
  2.  
  3. int main() {
  4. const bool z = true;
  5. const int x = 5, y = 3;
  6. int arr[[&]() -> int{return z ? x : y;}];
  7. return 0;
  8. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function ‘int main()’:
prog.cpp:6:11: error: expected ‘]’ before ‘&’ token
  int arr[[&]() -> int{return z ? x : y;}];
           ^
prog.cpp:6:41: error: expected initializer before ‘]’ token
  int arr[[&]() -> int{return z ? x : y;}];
                                         ^
stdout
Standard output is empty