Skip to main content
Module 4 · Manhattan Navigation

Lesson 4-5 · Turning — Knowledge Checks

Name Date
  1. The robot faces West (3) and makes one clockwise turn. What does (heading + 1) % 4 give?

    1. A.4
    2. B.0, North: 4 % 4 is 0, so the heading wraps around
    3. C.3, because West is the last heading
    4. D.An error, because there is no heading 4

    Answer Why?

  2. A student's printout shows turning clockwise forever after the first move. What's the likely bug?

    1. A.The planner returned the wrong path
    2. B.turn_to() never changes current_heading inside the loop, so the condition never becomes False
    3. C.HEADING_NAMES is in the wrong order
    4. D.The robot is not on the grid

    Answer Why?