'select move; unexplored children first, then according to uct value'

def select(self, board):

    if self.unexplored:
        i = random.randrange(len(self.unexplored))
        pos = self.unexplored[i]
        self.unexplored[i] = self.unexplored[(len(self.unexplored) - 1)]
        self.unexplored.pop()
        return pos
    elif self.bestchild:
        return self.bestchild.pos
    else:
        return PASS
