Increase array limit
int cheque[300] = {0};
Always print a newline after last line.
for(i = 0; i < game; i++)
{
if(cheque[i] == 0) printf("Game #%i: no king is in check.", i + 1);
if(cheque[i] == 1) printf("Game #%i: white king is in check.", i + 1);
if(cheque[i] == 2) printf("Game #%i ...
Search found 2 matches
- Fri Sep 26, 2014 2:07 am
- Forum: Volume 101 (10100-10199)
- Topic: 10196 - Check The Check
- Replies: 77
- Views: 36150
- Sun Sep 21, 2014 2:25 am
- Forum: Volume 101 (10100-10199)
- Topic: 10196 - Check The Check
- Replies: 77
- Views: 36150
Re: 10196 - Check The Check
[ANSI C]
Can someone plz tell me why I got WA ?
#include <stdio.h>
#include <stdlib.h>
char field[8][8];
int black_king[2];
int white_king[2];
int isTheEnd()
{
white_king[0] = -1;
white_king[1] = -1;
black_king[0] = -1;
black_king[1] = -1;
int i, j, temp = 1;
for(i = 0; i < 8; ++i ...
Can someone plz tell me why I got WA ?
#include <stdio.h>
#include <stdlib.h>
char field[8][8];
int black_king[2];
int white_king[2];
int isTheEnd()
{
white_king[0] = -1;
white_king[1] = -1;
black_king[0] = -1;
black_king[1] = -1;
int i, j, temp = 1;
for(i = 0; i < 8; ++i ...