chapter

    Adversarial Search, Minimax and Alpha-beta Pruning Notes for Gate Da

    Adversarial Search, Minimax and Alpha-beta Pruning notes for GATE DA: 14 study cards covering concepts, formulas, shortcuts and exam traps, plus solved practi

    Adversarial Search Minimax and Alpha Beta Pruning notes

    Chapter Roadmap: Adversarial Search

    1
    Minimax Game Tree Evaluation and Strategy Selection
    Foundation of adversarial search. Learn how MAX and MIN agents propagate utility values from terminal states to the root to select optimal strategies in deterministic, perfect-information games.
    Importance: High | Core Dependency for all game-playing AI
    2
    Alpha-Beta Pruning Bounds and Interpretation
    Optimization of minimax. Learn to maintain alpha and beta bounds to identify and prune branches that cannot possibly influence the final decision, without changing the final result.
    Importance: Moderate to High | Frequent Exam Application

    Topic Hero: The Minimax Intuition

    The Adversarial Setting

    Minimax applies strictly to games with three properties:

    • Two-player: Exactly two agents taking turns.
    • Zero-sum: The utility of the game is strictly opposed. If MAX gains , MIN effectively gains .
    • Perfect information: No hidden states or chance elements (no dice, no hidden cards).

    The Core Assumption

    The algorithm is built on a single, critical premise: The opponent plays optimally. When MAX evaluates a move, it does not hope for MIN to make a mistake. It assumes MIN will always choose the branch that yields the lowest possible utility for MAX. Therefore, MAX's strategy is to maximize the minimum possible payoff (hence, "Minimax").

    Bottom-Up Value Propagation

    The minimax value of a node is determined recursively based on its children:

    Terminal Nodes (Leaves): Evaluated directly by the utility function, .

    MIN Nodes: The minimizing player chooses the action that leads to the state with the lowest value.

    MAX Nodes: The maximizing player chooses the action that leads to the state with the highest value.

    This recursive definition guarantees that the value propagating to the root represents the best achievable outcome for MAX, assuming optimal play from both sides.

    11 more cards in this chapter

    Try a question

    Answer it here to see how it works. Nothing is recorded until you sign in.

    Question 1
    Level 1: Warm-up

    Match the node types in a minimax game tree (List I) with their corresponding evaluation rules (List II):

    List I

    • P. MAX node
    • Q. MIN node
    • R. Terminal node

    List II

    • 1. Value = minimum of children's values
    • 2. Value = maximum of children's values
    • 3. Value = output of utility function

    Choose the correct matching:

    Question 2
    Level 1: Warm-up

    Match the node types in a minimax game tree (List I) with their corresponding evaluation formulas (List II):

    List I

    • P. Terminal Node
    • Q. MIN Node
    • R. MAX Node

    List II

    • 1.
    • 2.
    • 3.

    Choose the correct matching:

    Question 3
    Level 1: Warm-up

    Match the node operations (List I) with their corresponding bound updates (List II) during alpha-beta traversal:

    List I

    • P. MAX node evaluates a child with value
    • Q. MIN node evaluates a child with value
    • R. Root node initialization

    List II

    • 1.
    • 2.
    • 3.

    Choose the correct matching:

    Question 4
    Level 1: Warm-up

    In a strictly two-player, zero-sum game with perfect information, the utility function evaluates a specific terminal state as for the MAX player. What is the corresponding utility value for the MIN player at this exact same state?

    Question 5
    Level 1: Warm-up

    Consider a 2-ply game tree where the root is a MAX node with three children, which are MIN nodes. The terminal leaves for these MIN nodes are as follows:

    • Child 1:
    • Child 2:
    • Child 3:

    How many terminal nodes in this tree have a utility value strictly greater than the minimax value of the root?

    Question 6
    Level 1: Warm-up

    Consider a 2-ply game tree. The root is a MAX node with two children, and , which are MIN nodes.

    has leaves: .

    has leaves: .

    How many terminal nodes in the entire tree have a utility value strictly greater than the final minimax value of the root?

    Question 7
    Level 1: Warm-up

    In a two-player zero-sum game with perfect information, the current state is a MIN node. The MIN player has three available moves, leading to terminal states with utility values , , and for the MAX player. Assuming both players play optimally, what is the maximum utility value that the MAX player can guarantee from this position?

    Question 8
    Level 1: Warm-up

    A MAX node in a minimax game tree has three child nodes with evaluated minimax values of $4$, $-2$, and $7$. What is the evaluated value of this MAX node?

    Question 9
    Level 1: Warm-up

    In a strictly two-player, zero-sum game with perfect information, what is the maximum possible value of the sum of the utility functions for both players at any terminal state?

    Question 10
    Level 1: Warm-up

    Assertion (A): If and at a MIN node, the remaining children of this MIN node are pruned.

    Reason (R): Pruning occurs only when is strictly greater than .

    Choose the correct option:

    Free preview ends here

    Login to view the complete notes

    Creating an account is free. You get the rest of this chapter, step-by-step solutions, and a study plan built around the topics you are actually weak at.

    Explore complete test series, official past papers, and chapter-wise study tools.

    Why MastersUp

    Personalised first. High quality throughout.

    Most platforms hand everyone the same content. Here the content moves with your performance, topic by topic.

    Built around you, not around a syllabus PDF

    Every answer you give moves your topic-level intelligence rate. The next question, the next revision card and tomorrow's plan all change with it.

    Revision that hits your weak spots

    We only revise topics you have actually attempted and are still below the safe bar on — never the same chapter on repeat.

    Questions calibrated to the real exam

    Each question carries a measured toughness. You are served a rung above your current level, so practice keeps stretching you.

    Notes written for recall, not for volume

    Full lesson cards for first study, curated short-note cards for the last mile — with derivations, traps and exam patterns marked.

    One place for everything

    Notes, chapter practice, previous-year questions, test series and full-length papers — all feeding one picture of your preparation.

    Honest progress

    No vanity streaks. Progress here means chapters mastered and accuracy that held up on harder questions.

    Unlock the whole course

    Full notes and short notes, the complete question bank with worked solutions, mock tests, full-length papers, and an adaptive plan that rebuilds itself as you improve.

    Adversarial Search, Minimax and Alpha-beta Pruning Notes for GATE DA

    Adversarial Search, Minimax and Alpha-beta Pruning notes for GATE DA: 14 study cards covering concepts, formulas, shortcuts and exam traps, plus solved practice questions.

    Chapter Roadmap: Adversarial Search

    1
    Minimax Game Tree Evaluation and Strategy Selection
    Foundation of adversarial search. Learn how MAX and MIN agents propagate utility values from terminal states to the root to select optimal strategies in deterministic, perfect-information games.
    Importance: High | Core Dependency for all game-playing AI
    2
    Alpha-Beta Pruning Bounds and Interpretation
    Optimization of minimax. Learn to maintain alpha and beta bounds to identify and prune branches that cannot possibly influence the final decision, without changing the final result.
    Importance: Moderate to High | Frequent Exam Application

    Topic Hero: The Minimax Intuition

    The Adversarial Setting

    Minimax applies strictly to games with three properties:

    • Two-player: Exactly two agents taking turns.
    • Zero-sum: The utility of the game is strictly opposed. If MAX gains , MIN effectively gains .
    • Perfect information: No hidden states or chance elements (no dice, no hidden cards).

    The Core Assumption

    The algorithm is built on a single, critical premise: The opponent plays optimally. When MAX evaluates a move, it does not hope for MIN to make a mistake. It assumes MIN will always choose the branch that yields the lowest possible utility for MAX. Therefore, MAX's strategy is to maximize the minimum possible payoff (hence, "Minimax").

    Bottom-Up Value Propagation

    The minimax value of a node is determined recursively based on its children:

    Terminal Nodes (Leaves): Evaluated directly by the utility function, .

    MIN Nodes: The minimizing player chooses the action that leads to the state with the lowest value.

    MAX Nodes: The maximizing player chooses the action that leads to the state with the highest value.

    This recursive definition guarantees that the value propagating to the root represents the best achievable outcome for MAX, assuming optimal play from both sides.

    Step-by-Step Tree Evaluation Method

    Follow this strict sequence to avoid errors in complex trees:

    1
    Anchor the Leaves: Identify all terminal nodes. Write their utility values clearly next to them.
    2
    Resolve the Lowest Internal Level: Look at the parents of the terminal nodes. If the parent is a MIN node, circle the minimum value among its children. If it is a MAX node, circle the maximum value.
    3
    Propagate Upward: Treat the newly filled internal nodes as the "leaves" for the next level up. Repeat step 2.
    4
    Determine Root Value and Strategy: The final value at the root is the Minimax value. To find MAX's optimal first move, trace the path from the root to the child that originally provided this maximum value.

    Adversarial Search, Minimax and Alpha-beta Pruning: Solved Questions with Step-by-Step Explanations (10 Problems)

    Question 1 · Artificial Intelligence MCQ

    Match the node types in a minimax game tree (List I) with their corresponding evaluation rules (List II):

    List I

    • P. MAX node
    • Q. MIN node
    • R. Terminal node

    List II

    • 1. Value = minimum of children's values
    • 2. Value = maximum of children's values
    • 3. Value = output of utility function

    Choose the correct matching:

    1. A.

      P-2, Q-1, R-3

    2. B.

      P-1, Q-2, R-3

    3. C.

      P-2, Q-3, R-1

    4. D.

      P-3, Q-1, R-2

    Correct Answer:

    A

    Step-by-Step Solution

    Key idea: Each node type in a minimax tree has a specific evaluation rule. Match them correctly. Step 1: Evaluate P (MAX node). - MAX wants to maximize utility. - At a MAX node, we take the maximum of children's values. - P matches with 2. Step 2: Evaluate Q (MIN node). - MIN wants to minimize MAX's utility. - At a MIN node, we take the minimum of children's values. - Q matches with 1. Step 3: Evaluate R (Terminal node). - Terminal nodes are end states of the game. - They are evaluated directly by the utility function. - R matches with 3. Step 4: Combine the matches. - P-2, Q-1, R-3 Answer: P-2, Q-1, R-3
    Question 2 · Artificial Intelligence MCQ

    Match the node types in a minimax game tree (List I) with their corresponding evaluation formulas (List II):

    List I

    • P. Terminal Node
    • Q. MIN Node
    • R. MAX Node

    List II

    • 1.
    • 2.
    • 3.

    Choose the correct matching:

    1. A.

      P-3, Q-1, R-2

    2. B.

      P-1, Q-2, R-3

    3. C.

      P-3, Q-2, R-1

    4. D.

      P-2, Q-3, R-1

    Correct Answer:

    C

    Step-by-Step Solution

    Key idea: This is a matching question testing the fundamental evaluation formulas for each node type in a minimax tree.

    Step 1: Evaluate P (Terminal Node).

    • Terminal nodes are the leaves where the game ends.
    • They are evaluated directly by the utility function.
    • P matches with 3.

    Step 2: Evaluate Q (MIN Node).

    • MIN nodes represent the minimizing player's turn.
    • The value is the minimum of its children's values.
    • Q matches with 2.

    Step 3: Evaluate R (MAX Node).

    • MAX nodes represent the maximizing player's turn.
    • The value is the maximum of its children's values.
    • R matches with 1.

    Step 4: Combine the matches.

    • P-3, Q-2, R-1

    Answer: P-3, Q-2, R-1

    Question 3 · Artificial Intelligence MCQ

    Match the node operations (List I) with their corresponding bound updates (List II) during alpha-beta traversal:

    List I

    • P. MAX node evaluates a child with value
    • Q. MIN node evaluates a child with value
    • R. Root node initialization

    List II

    • 1.
    • 2.
    • 3.

    Choose the correct matching:

    1. A.

      P-2, Q-1, R-3

    2. B.

      P-1, Q-2, R-3

    3. C.

      P-3, Q-1, R-2

    4. D.

      P-1, Q-3, R-2

    Correct Answer:

    B

    Step-by-Step Solution

    Key idea: This is a bounding question testing the update rules for alpha and beta during tree traversal.

    Step 1: Evaluate P (MAX node update).

    • MAX wants to maximize its guaranteed value.
    • When a MAX node evaluates a child with value , it updates to be the maximum of its current and .
    • Formula: .
    • P matches with 1.

    Step 2: Evaluate Q (MIN node update).

    • MIN wants to minimize MAX's guaranteed value.
    • When a MIN node evaluates a child with value , it updates to be the minimum of its current and .
    • Formula: .
    • Q matches with 2.

    Step 3: Evaluate R (Root initialization).

    • The search starts with no bounds established.
    • is initialized to and to .
    • R matches with 3.

    Step 4: Combine the matches.

    • P-1, Q-2, R-3

    Answer: P-1, Q-2, R-3

    Question 4 · Artificial Intelligence MCQ

    In a strictly two-player, zero-sum game with perfect information, the utility function evaluates a specific terminal state as for the MAX player. What is the corresponding utility value for the MIN player at this exact same state?

    1. A.

    2. B.

    3. C.

      $0$

    4. D.

      $16$

    Correct Answer:

    B

    Step-by-Step Solution

    Insight: In a zero-sum game, the sum of the players' utilities is always zero.

    Exam route: Utility for MIN = -(Utility for MAX) = -(+8) = -8.

    Learning route:

    Step 1: Recall the definition of a zero-sum game: one player's gain is exactly the other player's loss.

    Step 2: Mathematically, this means for any state .

    Step 3: Given , we solve for .

    Step 4: .

    Answer:

    Question 5 · Artificial Intelligence MCQ

    Consider a 2-ply game tree where the root is a MAX node with three children, which are MIN nodes. The terminal leaves for these MIN nodes are as follows:

    • Child 1:
    • Child 2:
    • Child 3:

    How many terminal nodes in this tree have a utility value strictly greater than the minimax value of the root?

    1. A.

      1

    2. B.

      2

    3. C.

      3

    4. D.

      4

    Correct Answer:

    B

    Step-by-Step Solution

    Insight: Evaluate bottom-up to find the root value first, then count the leaves strictly greater than it.

    Exam route: MIN nodes give 4, 5, 1. MAX root gives 5. Leaves > 5 are 8 and 9. Count is 2.

    Learning route: First, evaluate the MIN nodes: min(4, 8) = 4, min(5, 5) = 5, min(9, 1) = 1. Next, evaluate the MAX root: max(4, 5, 1) = 5. The minimax value of the root is 5. Finally, inspect all terminal leaves (4, 8, 5, 5, 9, 1) and count those strictly greater than 5. The values 8 and 9 satisfy this, giving a count of 2.

    Wrong path: A student might count leaves strictly greater than 4 (the first MIN node's value), which gives 8, 5, 5, 9 (count 4), or they might include 5 itself, leading to option C. This happens by misreading the condition "strictly greater than the root value".

    Generalization: Always complete the full bottom-up evaluation to find the exact root value before applying any filtering condition to the leaves.

    Question 6 · Artificial Intelligence MCQ

    Consider a 2-ply game tree. The root is a MAX node with two children, and , which are MIN nodes.

    has leaves: .

    has leaves: .

    How many terminal nodes in the entire tree have a utility value strictly greater than the final minimax value of the root?

    1. A.

      3

    2. B.

      4

    3. C.

      5

    4. D.

      6

    Correct Answer:

    B

    Step-by-Step Solution

    Insight: Find the root value first, then count only the terminal leaves that are strictly greater than this specific root value.

    Exam route: M1 -> 10, M2 -> 8. Root -> max(10, 8) = 10. Leaves > 10 are 12, 14, 11, 15. Count is 4.

    Learning route: First, evaluate the MIN nodes: M1 evaluates to min(10, 12, 14) = 10, and M2 evaluates to min(8, 11, 15) = 8. The root is a MAX node, so it evaluates to max(10, 8) = 10. The final minimax value of the root is 10. Now, inspect all terminal leaves in the tree: 10, 12, 14, 8, 11, 15. The values strictly greater than 10 are 12, 14, 11, and 15. There are exactly 4 such nodes.

    Wrong path: A student might count all leaves greater than 8 (the value of M2), which includes 10, 12, 14, 11, 15, giving a count of 5. This happens by comparing against a child node's value instead of the final root value, leading to overcounting.

    Generalization: When filtering terminal nodes based on the game's outcome, always use the final propagated root value as the threshold, not an intermediate node's value.

    Question 7 · Artificial Intelligence MCQ

    In a two-player zero-sum game with perfect information, the current state is a MIN node. The MIN player has three available moves, leading to terminal states with utility values , , and for the MAX player. Assuming both players play optimally, what is the maximum utility value that the MAX player can guarantee from this position?

    1. A.

    2. B.

    3. C.

    4. D.

      $0$

    Correct Answer:

    C

    Step-by-Step Solution

    Key idea: At a MIN node, the MIN player chooses the move that minimizes MAX's utility. MAX can only guarantee the minimum value MIN will allow.

    Step 1: Identify the node type. The current state is a MIN node, so MIN will choose the action that gives the lowest utility for MAX.

    Step 2: List the available utilities for MAX: , , .

    Step 3: MIN will select the minimum of these values: .

    Step 4: Since MIN plays optimally, MAX can guarantee at most from this position. MAX cannot force a higher value because MIN will always choose over or .

    Answer:

    Question 8 · Artificial Intelligence MCQ

    A MAX node in a minimax game tree has three child nodes with evaluated minimax values of $4$, $-2$, and $7$. What is the evaluated value of this MAX node?

    1. A.

    2. B.

      $4$

    3. C.

      $7$

    4. D.

      $9$

    Correct Answer:

    C

    Step-by-Step Solution

    Key idea: This is a direct formula application question for a MAX node. The MAX player always seeks to maximize the utility.

    Step 1: Identify the node type. The problem explicitly states this is a MAX node.

    Step 2: Recall the evaluation rule for a MAX node. The value of a MAX node is the maximum of its children's values.

    Step 3: Apply the rule to the given children values: $4$, , and $7$.

    Step 4: The evaluated value of the MAX node is $7$.

    Answer: $7$

    Question 9 · Artificial Intelligence MCQ

    In a strictly two-player, zero-sum game with perfect information, what is the maximum possible value of the sum of the utility functions for both players at any terminal state?

    1. A.

      $0$

    2. B.

      $1$

    3. C.

    4. D.

      Depends on the terminal state

    Correct Answer:

    A

    Step-by-Step Solution

    Key idea: This is a direct formula application question testing the fundamental property of zero-sum games.

    Step 1: Identify the game type. The problem explicitly states it is a "strictly zero-sum" game.

    Step 2: Recall the defining formula for a zero-sum game. In such games, one player's gain is exactly the other player's loss. Mathematically, for any terminal state :

    Step 3: Determine the maximum value of this sum. Since the sum is strictly constrained to be $0$ for every possible terminal state, the maximum possible value is exactly $0$.

    Step 4: Conclude the answer. The sum cannot be $1$, , or variable; it is always $0$.

    Answer: $0$

    Question 10 · Artificial Intelligence MCQ

    Assertion (A): If and at a MIN node, the remaining children of this MIN node are pruned.

    Reason (R): Pruning occurs only when is strictly greater than .

    Choose the correct option:

    1. A.

      Both A and R are true and R is the correct explanation of A

    2. B.

      Both A and R are true but R is not the correct explanation of A

    3. C.

      A is true but R is false

    4. D.

      A is false but R is true

    Correct Answer:

    C

    Step-by-Step Solution

    Key idea: This is a contradiction question testing the exact mathematical condition for pruning in alpha-beta search.

    Step 1: Evaluate Assertion (A).

    • "If and at a MIN node, the remaining children are pruned."
    • The pruning condition is .
    • Since is True, the remaining children are indeed pruned.
    • Therefore, A is TRUE.

    Step 2: Evaluate Reason (R).

    • "Pruning occurs only when is strictly greater than ."
    • This claims the condition is .
    • However, the actual condition is (greater than or equal to).
    • Therefore, R is FALSE.

    Step 3: Determine the relationship.

    • A is TRUE, R is FALSE.

    Answer: A is true but R is false

    More notes in this unit