From fce4fbb00b8dddc785b6761bc73aa89170093994 Mon Sep 17 00:00:00 2001 From: vehme003 Date: Thu, 25 Mar 2021 12:06:24 -0500 Subject: Add files via upload --- board2.py | 13 +++++++++++++ main2.py | 10 ++++++++++ 2 files changed, 23 insertions(+) create mode 100644 board2.py create mode 100644 main2.py diff --git a/board2.py b/board2.py new file mode 100644 index 0000000..1672ec8 --- /dev/null +++ b/board2.py @@ -0,0 +1,13 @@ +from random import * + +class Board: #A class for managing different situations and states happening in the game and on the board + def __init__(self, board): + self.board=board + def print_board(self): + for i in self.board: + for j in i: + print(j,end="") + print() + def play_move(r,c) + if(r%2==1): + \ No newline at end of file diff --git a/main2.py b/main2.py new file mode 100644 index 0000000..c9bedaf --- /dev/null +++ b/main2.py @@ -0,0 +1,10 @@ +from board2 import * + +def main(): + board =[["*", " ", " ", " ","*", " ", " ", " ","*", " ", " ", " ","*"],[" "," "," "," "," "," "," "," "," "," "," "," "," "],["*", " ", " ", " ","*", " ", " ", " ","*", " ", " ", " ","*"],[" "," "," "," "," "," "," "," "," "," "," "," "," "],["*", " ", " ", " ","*", " ", " ", " ","*", " ", " ", " ","*"],[" "," "," "," "," "," "," "," "," "," "," "," "," "],["*", " ", " ", " ","*", " ", " ", " ","*", " ", " ", " ","*"]] + Board=Board(board) + Board.print_board() + + + +main() \ No newline at end of file -- cgit v1.2.3