# -*- coding:utf-8 -*-

class Board:
    def checkWon(self, board):
        # write code here
        # 最笨的办法,每种情况都考虑,逐一排查
        if board[0][0] + board[1][1] + board[2][2] == 3:
            return True
        if board[0][2] + board[1][1] + board[2][0] == 3:
            return True
        
        for i in range(2):
            if board[i][0] + board[i][1] + board[i][2] == 3:
                return True
            if board[0][i] + board[1][i] + board[2][i] == 3:
                return True
        return False