text: import numpy as np
  
  
  class RandomPlayer():
      def __init__(self, game):
          self.game = game
  
      def play(self, board):
          a = np.random.randint(self.game.getActionSize())
          valids = self.game.getValidMoves(board, 1)
          while valids[a]!=1:
              a = np.random.randint(self.game.getActionSize())
          return a
  
  
  class HumanConnect3Player():
      def __init__(self, game):
          self.game = game
  
      def play(self, board):
          # display(board)
          valid = self.game.getValidMoves(board, 1)
          for i in range(len(valid)):
              if valid[i]:
                  print("[", i, end="] ")
          while True:
              input_a = input()
              try:
                  a = int(input_a)
                  if 0 <= a < self.game.xdim and valid[a]:
                      break
              except ValueError:
                  # Input needs to be an integer
                  'Invalid integer'
              print('Invalid move')
          return a
  
  
  # class GreedyOthelloPlayer():
  #     def __init__(self, game):
  #         self.game = game
  #
  #     def play(self, board):
  #         valids = self.game.getValidMoves(board, 1)
  #         candidates = []
  #         for a in range(self.game.getActionSize()):
  #             if valids[a]==0:
  #                 continue
  #             nextBoard, _ = self.game.getNextState(board, 1, a)
  #             score = self.game.getScore(nextBoard, 1)
  #             candidates += [(-score, a)]
  #         candidates.sort()
  #         return candidates[0][1]
  