fork download
  1. #include <stdio.h>
  2. #include <stdint.h>
  3.  
  4. int main() {
  5. uint32_t vec[6][3] = {
  6. {10, 11, 12},
  7. {20, 21, 22},
  8. {30, 31, 32},
  9. {40, 41, 42},
  10. {50, 51, 52},
  11. {60, 61, 62},
  12. };
  13. int i=0, j=0;
  14. for(auto it: vec[++i]) {
  15. fprintf(stdout, "%u\n", it);
  16. if( ++j>5 ) return 0; /// а иначе у тебя сегфолт
  17. }
  18. return 0;
  19. }
  20.  
Success #stdin #stdout 0s 2852KB
stdin
Standard input is empty
stdout
20
21
22