Added print board

This commit is contained in:
Paulina Nowak 2020-12-20 01:53:52 +01:00
commit 4ad4eff06a

19
main.py Normal file
View File

@ -0,0 +1,19 @@
"""
| |
-|-|-
| |
-|-|-
| |
"""
def print_board(state):
board = ""+ state[0] +"|"+ state[1] +"|"+ state[2] +" \n-|-|-\n"+ state[3] +"|"+ state[4] +"|"+ state[5] +"\n-|-|-\n"+ state[6] +"|"+ state[7] +"|"+ state[8] +"\n"
print(board)
state = list(" "*9)
print_board(state)
state[0] = "X"
print_board(state)