Exercise 1

Visual

Exercise 2

y := n;
result := 1;
while !y > 0 do
	(result := !result * !x;
	 y := !y - 1)

Exercise 3

while True do skip

Exercise 4

Configurations are and . Transitions for the first one are:

Transitions for the second one are:

Based on the properties:

  1. If , then .
  2. If does not terminate then does not terminate.

We can prove that they have the same semantics as they:

  • Are both non-terminating
  • Have the same result

Exercise 5

In PLD work repository.