Alterna · учебный материал

Robot perpetrator

Interactive Robot: the walls between the cells, target, pasting, strolling, syntax errors and failure.

Что в этом материале

Содержание и основные понятия

♪ Back to the map of themes
Alterna · Chapter 32 · page 32.1
Robot perpetrator
Cellular environment, walls at borders, paint and the exact reason for the stop.
Robot has no direction forward: each team indicates the absolute side. The wall prohibits the transition between the two cells, but does not replace the cell. Before execution, the entire program is syntaxed.
Robot
Hand track
EEG 15 framework
01
Environment and command system
вверх
строка уменьшается на 1
вниз
строка увеличивается на 1
влево
столбец уменьшается на 1
вправо
столбец увеличивается на 1
закрасить
текущая клетка становится закрашенной
стена / граница
команда движения неприменима: отказ
Verification procedure
First, all lines are clear. The unknown team is a syntax error, so no step is accomplished. A collision with a known wall is detected during performance and is called a refusal.
02
One route
The complete program shows how Robot changes the cell. Press "The Next Event" and check the status with the team.
Completed programme
The editor is hidden: there's a short path and the program changes are in the workshop.
Programme
Robot teams
Field
Status
active line
03
Three different troubles
Syntax error
The string doesn't belong to the command system. The program is being turned down all the way to traffic.
Refuse
The team is known, but not applicable in the current cell because of the wall or the border.
Logical error
All teams have been completed, but the target, the painting or other postage has not been achieved.
Success
The program is synthetically correct, has not been rejected and has met all the requirements of the task.
04
Next level
From route to algorithm
Repeatable commands are reduced by a cycle, and the path choice is given by an environment sensor. On the next page, one program is checked in multiple settings.

Structural map of textbooks