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 dx2-66
from typing import List
def checkio(game_result: List[str]) -> str:
full_result = (game_result + [''.join(s) for s in zip(*game_result)] +
[''.join([game_result[i][i] for i in range(0, 3)])] +
[''.join([game_result[i][2-i] for i in range(0,3)])])
if 'XXX' in full_result:
return 'X'
elif 'OOO' in full_result:
return 'O'
return 'D'
Dec. 30, 2021
Comments: