Prev: X3 Next: X5
Back to midtern page: Link, final page: Link

# X4 Practice Exam Problems

📗 Enter your ID (the wisc email ID without @wisc.edu) here: and click (or hit enter key)
📗 The same ID should generate the same set of questions. Your answers are not saved when you close the browser. You could print the page: , solve the problems, then enter all your answers at the end. 
📗 Please do not refresh the page: your answers will not be saved.

# Warning: please enter your ID before you start!


# Question 1


# Question 2


# Question 3


# Question 4


# Question 5


# Question 6


# Question 7


# Question 8


# Question 9


# Question 10


# Question 11


# Question 12


# Question 13


# Question 14


# Question 15


📗 [2 points] Consider a 3-puzzle where, like in the usual 8-puzzle game, a tile can only move to an adjacent empty space. Tiles cannot move diagonally. Which of the following initial states can reach the goal state (0 means "no tile")?
📗 Choices:





None of the above
📗 [4 points] Suppose the states are integers between and . The initial state is , and the goal state is . The successors of a state \(i\) are \(2 i\) and \(2 i + 1\), if exist. How many states are expanded using a Breadth First Search? Include both the initial and goal states.
📗 Note: use the convention used in the lectures, enqueue the states with smaller index into the queue first.
📗 Answer: .
📗 [4 points] Suppose the states are integers between and . The initial state is , and the goal state is . The successors of a state \(i\) are \(2 i\) and \(2 i + 1\), if exist. How many states are expanded using a Depth First Search? Include both the initial and goal states.
📗 Note: use the convention used in the lectures, push the states with larger index into the stack first (i.e. expand the states with the smaller index first).
📗 Answer: .
📗 [4 points] Suppose the state space has \(n\) = states that form a tree with root state \(0\). What is the shape of the tree that makes iterative deepening realize that a goal does not exist as quickly as possible (i.e. one that minimizes the number of expanded nodes)? Enter the number of nodes searched in this case.
📗 Answer: .
📗 [4 points] Consider search algorithm on the following grid, starting from state 0 with the goal state being , and one can move left, right, up, or down one step at a time (no wrapping around). The cost is the number of moves taken, and the heuristic is the Manhattan distance to the goal. Write down the expansion path (in the order of the states expanded). Break tie by expanding the state with a smaller index.
0 1 2
3 4 5
6 7 8

📗 Answer (comma separated vector): .
📗 [4 points] Let the states be 3D integer points with integer coordinates \(\left(i, j, k\right)\) with boundary constrains and and . Each state \(\left(i, j, k\right)\) has six successors \(\left(i - 1, j, k\right), \left(i + 1, j, k\right), \left(i, j - 1, k\right), \left(i, j + 1, k\right), \left(i, j, k - 1\right), \left(i, j, k + 1\right)\) or a subset thereof subject to the boundary constraints. The score of state \(\left(i, j, k\right)\) is . Which local minimum will be reached if hill climbing is used starting from ? Enter the state, not the score.
📗 Answer (comma separated vector): .
📗 [3 points] When using Simulated Annealing, which value of temperature \(T\) from the list would imize the probability of moving to an inferior (worse) state? Enter one value of \(T\), not its index in the list.
📗 Answer: .

📗 [4 points] When using the Genetic Algorithm, suppose the states are \(\begin{bmatrix} x_{1} & x_{2} & ... & x_{T} \end{bmatrix}\) = , , , . Let \(T\) = , the fitness function (not the cost) is \(\mathop{\mathrm{argmin}}_{t \in \left\{1, ..., T + 1\right\}} x_{t} = 1\) with \(x_{T + 1} = 1\) (i.e. the index of the first feature that is 1). What is the reproduction probability of the state with the highest reproduction probability?
📗 Answer: .
📗 [4 points] When using the Genetic Algorithm, suppose the states are \(\begin{bmatrix} x_{1} & x_{2} & ... & x_{T} \end{bmatrix}\) = , , , . Let \(T\) = , the fitness function (not the cost) is \(\mathop{\mathrm{argmin}}_{t \in \left\{1, ..., T + 1\right\}} x_{t} = 1\) with \(x_{T + 1} = 1\) (i.e. the index of the first feature that is 1). What is the reproduction probability of the first state: ?
📗 Answer: .
📗 [4 points] Consider the following zero-sum game tree. MAX player moves first. Draw a new game tree by re-ordering the children of each internal node (including the root), such that the new game is equivalent to the tree above, but alpha-beta pruning will prune as many nodes as possible. (You do not have to submit the drawing.) Enter the number of nodes pruned.

📗 Answer: .
📗 [2 points] Consider a game board consisting of bits initially at . Each player can simultaneously flip any number of bits in a move, but needs to pay the other player one dollar for each bit flipped. The player who achieves wins and collects dollars from the other player. What is the game theoretic value (in dollars) of this game for the first player?
📗 Note: "game theoretic value" is what we called "value of the game" in the lectures.
📗 Answer: .
📗 [3 points] Consider a variant of the II-nim game. There are two piles, each pile has \(n\) = sticks. A player can take one stick from a single pile; or take two sticks, one from each pile (when available). The player who takes the last stick wins. Let the game value be 1 if the first player wins (and -1 if the second player wins). What is the game theoretical value of this game?
📗 Answer: .
📗 [4 points] Consider a zero-sum sequential move game with Chance. Max player moves first, then Chance, then Min. The values of the terminal states are shown in the diagram (they are the values for the Max player). What is the (expected) value of the game (for the Max player)?

📗 Answer: .
📗 [4 points] Given the following BoS (Battle of Sexes) game, what is the column (Juliet) player's (expected) value (i.e. payoff) in the mixed strategy Nash equilibrium?
Romeo \ Juliet Bach Stravinsky
Bach
Stravinsky

📗 Answer: .
📗 [4 points] Given the following game payoff table, suppose the row player uses a pure strategy, and column player uses a mixed strategy playing L with probability \(q\). What is the smallest and largest value of \(q\) in a mixed strategy Nash equilibrium?
Row \ Col L R
U
D

Note: the following is a diagram of the best responses (make sure you understand what they are and how to draw them). The red curve is the best response for the column player and the blue curve is the best response for the row player.

📗 Answer (comma separated vector): .

# Grade


 ***** ***** ***** ***** ***** 

 ***** ***** ***** ***** *****


📗 You could save the text in the above text box to a file using the button or copy and paste it into a file yourself .
📗 You could load your answers from the text (or txt file) in the text box below using the button . The first two lines should be "##x: 4" and "##id: your id", and the format of the remaining lines should be "##1: your answer to question 1" newline "##2: your answer to question 2", etc. Please make sure that your answers are loaded correctly before submitting them.







Last Updated: April 29, 2024 at 1:11 AM