icp/oer/courses/c-newcomers/sections/03-lift/04-goal/content.md

508 B

Our Lift can now move up and down, but it still doesn't have any ability to move to a specific floor.

Model

To represent that in the model, we added the variable TargetFloor, which indicates to what floor the lift should move. You have to check if the lift has to move up or down. When the lift reached the target, it should stop for now.

Task

Your task is to implement the movement to that floor. It should take the shortest route. When it reached the target, set the variable isDone to true.