-
-
Save parzibyte/84c32967bbcc42d61c0ffbc52c231114 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static int colocarPieza(string jugador, int columna, string[,] tablero) | |
{ | |
if (columna < 0 || columna >= COLUMNAS) | |
{ | |
return ERROR_FILA_INVALIDA; | |
} | |
int fila = obtenerFilaDesocupada(columna, tablero); | |
if (fila == FILA_NO_ENCONTRADA) | |
{ | |
return ERROR_COLUMNA_LLENA; | |
} | |
tablero[fila, columna] = jugador; | |
return ERROR_NINGUNO; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment