fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. int x[2][3] = { {1, 2, 3}, {4, 5, 6} };
  5.  
  6. for (int i = 0; i < 2; i++) {
  7. for (int j = 0; j < 3; j++) {
  8. printf("%d ", x[i][j]); // 数字の後にスペース
  9. }
  10. putchar('\n'); // 1行ごとに改行
  11. }
  12.  
  13. return 0;
  14. }
  15.  
  16.  
  17.  
Success #stdin #stdout 0s 5320KB
stdin
Standard input is empty
stdout
1 2 3 
4 5 6