From aa322c8b2e266d5252b603901592fe8d23293110 Mon Sep 17 00:00:00 2001 From: MohammadSefidgar <108987757+MohammadSefidgar@users.noreply.github.com> Date: Tue, 13 Dec 2022 10:58:58 +0000 Subject: [PATCH] Mohammad-board.js --- board-printer.js | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/board-printer.js b/board-printer.js index e11a262..bd450d2 100644 --- a/board-printer.js +++ b/board-printer.js @@ -15,13 +15,29 @@ ================= Test your function by calling it with an example tic-tac-toe board. */ +let board = [ + ['X', '_', '_'], + ['_', 'X', '_'], + ['O', 'O', 'X'] +]; export function printBoard(board) { + console.log(board); + + } +printBoard(board); /* Given a tic-tac-toe board (an array of arrays), - return true if there are no moves left to make (there are no more '_' values) - return false if there are still moves that can be made */ -export function checkIfNoMovesLeft(board) { -} +let move = [ + ['X', '_', '_'], + ['_', 'X', '_'], + ['O', 'O', 'X'] +] +export function checkIfNoMovesLeft(move) { + console.log(move); +}; +checkIfNoMovesLeft(move) \ No newline at end of file