Elevator Riddle – HDT1817

  1. When the up button on the first floor is pressed, go down to the first floor, and open up the doors
  2. When I enter the elevator and press the fourth floor button, proceed to that floor, stopping at any floor in between (IF those buttons were pressed) to either let people off or on.
  3. Once the fourth floor is reached, open up the doors and let anyone going to the fourth floor out.
  4. Respond to a pushed up or down button and proceed to the floor where the button was pushed.
This entry was posted in Riddle. Bookmark the permalink.

1 Response to Elevator Riddle – HDT1817

  1. davidbdale's avatar davidbdale says:

    I like much of what is going on here, HDT. In many cases, you provide INSTRUCTIONS to the elevator, which is what the assignment requires. However, in other examples, you’re offering EXAMPLES, which the elevator would not recognize as instructions. Yes, the post is supposed to provide INSTRUCTIONS to the ELEVATOR (who is your reader here.) And Yes, the elevator reads your instructions and follows them.

    The elevator will not extrapolate from examples to create rules for itself. You need to spell out the rules as GENERAL INSTRUCTIONS and identify the EXCEPTIONS to the rules also in general terms.

    Some examples in no particular order:

    —In response to any CALL button, PROCEED to that floor and OPEN the doors.
    —You have three modes: AT REST, GOING UP, GOING DOWN.
    —When you are GOING DOWN, IGNORE any GOING UP requests.

    See what I mean?

    Provisionally graded out of gratitude for your outstanding contribution to the project and your effort. You may still earn a Regrade by transforming your descriptions of elevator operations into INSTRUCTIONS written for the elevator (as if the Elevator were your reader and needed to be told how to operate).

Leave a reply to davidbdale Cancel reply