Program EX_3;
var
a,b,c:real;
x1,x2:real;
D:real;
Begin
Writeln ('Reshenie kvadratnogo uravnenie');
Writeln ('Vvedite A');
Readln (a);
Writeln ('Vvedite b');
Readln (b);
Writeln ('Vvedite c');
Readln ( c);
D:=(b*b)-4*(a*c);
if D>0 then
x1:=(-b+sqrt(D))/(2*a);
x2:=(-b-sqrt(D))/(2*a);
Writeln ('Pervyi kopenb', x1);
Writeln ('VtopoI kopenb', x2)
end.
If D=0 then
x1:=-b/2*a;
Writeln ('Odin kopenb' , x1);
end;
If D<0 then
Writeln (HET KOPNEU');
Readln
end.
В следующий раз пользуйся тегами