Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Xs and Os Referee by Stepan__Timetsky
from typing import List
def checkio(game_result):
right, left = -1, 3
left_right, right_left = '', ''
while right < 3 and left > 0:
right += 1
left -= 1
left_right += game_result[right][right]
right_left += game_result[right][left]
game_result += [''.join(i) for i in list(zip(*game_result))]
game_result += [left_right, right_left]
print(game_result)
for i in game_result:
if i == 'OOO' or i == 'XXX':
return i[0]
return 'D'
June 28, 2019
Comments: