From 2839c42d5235ae73c6256ab9d58524a08b993cf4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Jan 2026 18:05:44 +0000 Subject: [PATCH 1/2] Bump ccxt from 4.5.30 to 4.5.31 Bumps [ccxt](https://github.com/ccxt/ccxt) from 4.5.30 to 4.5.31. - [Release notes](https://github.com/ccxt/ccxt/releases) - [Commits](https://github.com/ccxt/ccxt/compare/v4.5.30...v4.5.31) --- updated-dependencies: - dependency-name: ccxt dependency-version: 4.5.31 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- requirements_with_versions.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements_with_versions.txt b/requirements_with_versions.txt index fefa2acb8b2..5fdcba63e65 100644 --- a/requirements_with_versions.txt +++ b/requirements_with_versions.txt @@ -81,7 +81,7 @@ Unidecode==1.4.0 Ball==0.2.9 pynput==1.8.1 gTTS==2.5.4 -ccxt==4.5.30 +ccxt==4.5.31 fitz==0.0.1.dev2 fastapi==0.128.0 Django==6.0 From 24b8623f70d3e725456d109ae3c9ed7434470c19 Mon Sep 17 00:00:00 2001 From: Harsh Date: Wed, 7 Jan 2026 14:08:14 +0530 Subject: [PATCH 2/2] Update tic tac toe game --- tic-tac-toe.py | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 tic-tac-toe.py diff --git a/tic-tac-toe.py b/tic-tac-toe.py new file mode 100644 index 00000000000..30bc1c68ed8 --- /dev/null +++ b/tic-tac-toe.py @@ -0,0 +1,63 @@ +# Tic Tac Toe Game in Python + +board = [" " for _ in range(9)] + +def print_board(): + print() + print(f" {board[0]} | {board[1]} | {board[2]} ") + print("---|---|---") + print(f" {board[3]} | {board[4]} | {board[5]} ") + print("---|---|---") + print(f" {board[6]} | {board[7]} | {board[8]} ") + print() + +def check_winner(player): + win_conditions = [ + [0,1,2], [3,4,5], [6,7,8], # rows + [0,3,6], [1,4,7], [2,5,8], # columns + [0,4,8], [2,4,6] # diagonals + ] + for condition in win_conditions: + if all(board[i] == player for i in condition): + return True + return False + +def is_draw(): + return " " not in board + +current_player = "X" + +print("Welcome to Tic Tac Toe!") +print("Positions are numbered 1 to 9 as shown below:") +print(""" + 1 | 2 | 3 +---|---|--- + 4 | 5 | 6 +---|---|--- + 7 | 8 | 9 +""") + +while True: + print_board() + try: + move = int(input(f"Player {current_player}, choose position (1-9): ")) - 1 + if board[move] != " ": + print("That position is already taken. Try again.") + continue + except (ValueError, IndexError): + print("Invalid input. Enter a number between 1 and 9.") + continue + + board[move] = current_player + + if check_winner(current_player): + print_board() + print(f"🎉 Player {current_player} wins!") + break + + if is_draw(): + print_board() + print("🤝 It's a draw!") + break + + current_player = "O" if current_player == "X" else "X"