Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from random import randint
- import time
- szer = int(input("Podaj szerokosc: "))
- wys = int(input("Podaj wysokosc: "))
- while True:
- board = [["O" for i in range(szer)] for j in range(wys)]
- for i in range(szer):
- time.sleep(0.3)
- x=randint(1,szer)
- board[x-1][i] = "X"
- for j in range(wys):
- print(board[j][i], end=" ")
- board[j][x-1] = "O"
- if j==wys-1:
- print("\n")
Advertisement
Add Comment
Please, Sign In to add comment