Chris Pollett> Old Classses >
CS156

( Print View )

Student Corner:
[Submit Sec5]
[Grades Sec5]

[Lecture Notes]
[Discussion Board]

Course Info:
[Texts & Links]
[Description]
[Course Outcomes]
[Outcomes Matrix]
[Course Schedule]
[Grading]
[Requirements/HW/Quizzes]
[Class Protocols]
[Exam Info]
[Regrades]
[University Policies]
[Announcements]

HW Assignments:
[Hw1] [Hw2] [Hw3]
[Hw4] [Hw5] [Quizzes]

Practice Exams:
[Midterm] [Final]

CS156 Fall 2022Practice Midterm 1

Studying for one of my tests does involve some memorization. I believe this is an important skill. Often people waste a lot of time and fail to remember the things they are trying to memorize. Please use a technique that has been shown to work such as the method of loci. Other memorization techniques can be found off the Wiki Page for Moonwalking with Einstein. Given this, to study for the midterm I would suggest you:

  • Know how to do (by heart) all the practice problems.
  • Go over your notes at least three times. Second and third time try to see how much you can remember from the first time.
  • Go over the homework problems.
  • Try to create your own problems similar to the ones I have given and solve them.
  • Skim the relevant sections from the book.
  • If you want to study in groups, at this point you are ready to quiz each other.

The practice midterm is below. Here are some facts about the actual midterm: (a) It is closed book, closed notes. Nothing will be permitted on your desk except your pen (pencil) and test. (b) You should bring photo ID. (c) There will be more than one version of the test. Each version will be of comparable difficulty. (d) One problem (less typos) on the actual test will be from the practice test.

  1. What is the PEAS description of a task environment? Give a fully spelt-out example of a sequential task environment in terms of the four PEAS components.
  2. Give an example (to receive credit you always need to show why your example works) situation in which iterative deepening depth first search is slower than breadth first search. Give an example of a situation where iterative deepening depth first search can find a solution, but breadth first search cannot.
  3. Briefly describe the following three algorithms `A^\star`-search, `IDA^\star` search, `SMA^\star` search.
  4. Give an example of each of the following programming language features in Python: generators, coroutines, lambda.
  5. What is the space complexity (argue why you answer is correct) of hill climbing with `k` restarts, `k`-local beam search, simulated annealing?
  6. Give the minimax algorithm. How would it be modified if one had a game for which one could not fully expand the game tree? Draw a game tree with an alpha-cut and explain why it is an alpha-cut.
  7. Briefly explain under what conditions the `A^\star`-algorithm finds the optimal solution. How can one determine the effective branching factor of the `A^{\star}` algorithm for a particular heuristic. If I have two heuristics for `A^{\star}` such that this algorithm will return an optimal solution, explain how I could combine them to make a heuristic that performs as well as either one.
  8. Define the Bay Area to be the counties San Francisco, San Mateo, Santa Clara, Alameda, Contra Costa, Solano, Napa, Sonoma, and Marin. Express the map coloring problem using just three colors for these counties as a constraint satisfaction problem. Give an example solution.
  9. Give the AC-3 algorithm.
  10. Briefly explain the following heuristics for Backtracking Search solving CSPs: (a) minimum-remaining-value, (b) degree heuristic, (c) least-constraining-value.