I'm currently making a game of tic_tac_toe and I'm trying to make a function that will draw a grid with new information for every turn. Problem is that the "grid" board is moved when new information is entered.
Here's what I've tried:
row1 = ["", "", ""]
row2 = ["", "", ""]
row3 = ["", "", ""]
def gridDrawer (row1, row2, row3) :
print(f"| {row1[0]} |", f"{row1[1]}", f"| {row1[2]} |")
print(f"| {row2[0]} |", f"{row2[1]}", f"| {row2[2]} |")
print(f"| {row3[0]} |", f"{row3[1]}", f"| {row3[2]} |")
gridDrawer(row1, row2, row3)
row1[0] = 5 # This part moves the "|" if i call the gridDrawer() again.