Question
Use the alpha-beta pruning to explore the following game tree. The root node is MAX. Visit the successors from left to right. The pseudo-codes of
Use the alpha-beta pruning to explore the following game tree. The root node is MAX. Visit the successors from left to right. The pseudo-codes of the alpha-beta pruning is below
Write the final values (i.e., values after calling max-value() or min-value() function at the corresponding node) of alpha or beta at each node that is not pruned. The initial values of alpha and beta are and , respectively.
Write the utility value being returned at each node inside the trapezoid. Leave it blank if it is pruned. If its child node is pruned, ignore the utility value of the child node to get the utility value of the current node.
Put an X through the edges that are pruned off.
def value(state): if the state is a terminal state: return the state's utility if the next agent is MAX: return max-value(state) if the next agent is MIN: return min-value(state) def max-value(state, ,): \begin{tabular}{l|l|} initialize v= & def min-value ( state, ,) : \\ for each successor of state: & initialize v=+ \\ v=max(v, value(successor, ,)) & for each successor of state: \\ v=min(v, value(successor, ,)) \\ if v return v & if v return v \\ =max(,v) & =min(,v) \\ return v & return v \end{tabular}Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started