✅ Перевірена відповідь на це питання доступна нижче. Наші рішення, перевірені спільнотою, допомагають краще зрозуміти матеріал.
A robot runs this teleo-reactive program, whose rules are checked top to bottom on every cycle:
dirty(X,Y) -> do(clean)
not wall(front) -> do(forward)
wall(front) and not wall(left) -> do(turn(left))
wall(front) and wall(left) -> nil
In the current cycle it perceives that its square is dirty, there is a wall in front, and there is a wall to its left. Which action does it take?