Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Uncategorized category for Xs and Os Referee by UFO665
def checkio(result):
lst = ["".join(row[i] for row in result) for i in range(3)]
res = [row[0] for row in result + lst if row[0] != "." and row == row[0] * 3]
if res:
return res[0]
if result[1][1] != "." and (result[0][0] == result[1][1] == result[2][2] or result[0][2] == result[1][1] == result[2][0]):
return result[1][1]
return "D"
Dec. 5, 2015