Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created March 10, 2021 00:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/7ac0900015111f7e72b9cef97b1acf41 to your computer and use it in GitHub Desktop.
Save parzibyte/7ac0900015111f7e72b9cef97b1acf41 to your computer and use it in GitHub Desktop.
// Debería llamarse después de verificar si alguien gana
// Indica si hay un empate
int empate(char tableroOriginal[FILAS][COLUMNAS])
{
int y;
for (y = 0; y < FILAS; y++)
{
int x;
for (x = 0; x < COLUMNAS; x++)
{
// Si hay al menos un espacio vacío se dice que no hay empate
if (tableroOriginal[y][x] == ESPACIO_VACIO)
{
return 0;
}
}
}
return 1;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment