 # MINIMAX
 
-[MAX, MIN] = ['MAX', 'MIN']
+[MAX, MIN] = [1, 2]
 
 # Action :: Any
 

      β = Math.min β, v
    [v, a]

module.exports = { MAX, MIN, MinimaxAgent }

    [_, bestAction] = @minimax state
    bestAction

  minimax: (state, α = -Limit, β = +Limit, ply = 0) ->
    isTerminal = state.isTerminal()
    ++ply if not isTerminal and state.nextAgent() is @rootAgent
    if ply > @depth or isTerminal
