а)
var x, y: integer;
begin
write('Введите x: ');
readln(x);
write('Введите y: ');
readln(y);
y := y - x;
x := x - 2;
if x < y then
begin
y := y - x;
x := x - 2;
end;
writeln('x = ', x);
writeln('y = ', y);
end.
б)
var x, y: integer;
begin
write('Введите x: ');
readln(x);
write('Введите y: ');
readln(y);
y := y + x;
x := x - 2;
if x <> 0 then
begin
y := y + x;
x := x - 2;
end;
writeln('x = ', x);
writeln('y = ', y);
end.