program svs;
var
a,b:integer;
begin
a:= 1;
b:= 2;
while a > 0 do
b:= b - 2;
a:= a + b;
end;
b:= a + b;
writeln(b);
writeln(a);
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
program svs;
var
a,b:integer;
begin
a:= 1;
b:= 2;
while a > 0 do
begin
b:= b - 2;
a:= a + b;
end;
b:= a + b;
writeln(b);
writeln(a);
end.