Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int diag1 = abs(count1 - count2);
- int diag2 = (count1 + count2) - 7;
- int j = 0;
- for (diag1; diag1 < 8; diag1++) {
- if (a[diag1][j] != temp) {
- a[diag1][j] = 2;
- j++;
- }
- else
- j++;
- }
- j = 7;
- for (diag2; diag2 < 8; diag2++) {
- if (a[diag2][j] != temp) a[diag2][j] = 2;
- else
- j--;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement