fork download
  1. #include<cstdio>
  2. #include<cstring>
  3.  
  4. using namespace std;
  5.  
  6. int table[10][4];
  7. int i,j;
  8. int br;
  9.  
  10. int main()
  11. {
  12. br=1;
  13.  
  14. for(i=0;i<4;i++)
  15. {
  16. for(j=0;j<10;j++)
  17. {
  18. if(br%6==3) table[j][i]=2;
  19. else if(br%5==0 && br%6!=3) table[j][i]=3;
  20. else table[j][i]=1;
  21.  
  22. br++;
  23. }
  24. }
  25.  
  26.  
  27. for(i=0;i<4;i++)
  28. {
  29. for(j=0;j<10;j++)
  30. {
  31. printf("%d",table[j][i]);
  32. }
  33. printf("\n");
  34. }
  35.  
  36. return 0;
  37. }
Success #stdin #stdout 0s 3340KB
stdin
Standard input is empty
stdout
1121311123
1111211113
2111312113
1121311123