Проверте пожалуйста код. Кажется она неправильно работает
Код
procedure data(var a,b,c:real);
var i: byte; ch:char; a1,b1,c1:string; code:integer;
begin
writeln(' Enter coefficients of equation ');
i:=0;
repeat
read(ch);
if (ch=#13) then
begin
inc(i);
if i=1 then
val(a1,a,code);
if i=2 then
val(b1,b,code);
if i=3 then
val(c1,c,code);
end
else
begin
if i=0 then
a1:=a1+ch;
if i=1 then
b1:=b1+ch;
if i=2 then
c1:=c1+ch;
end;
until i=3;
end;