12.5.

S1 for x: 1

S2 for x (before changing): 1

S2 for x (after changing): 2

S3: 5

S1: yes, this is legal



12.6.

0

0