Program n ;
Var
a,b,c,x,d,x1,x2:real;
Begin
Write('donne la valeur a=');
Read(a);
Write('donne la valeur b=');
Readln(b);
Write('donne la valeur c=');
Readln(c);
If (a=0) and (b<>0)and (c<>0) then
Begin
x:=(-c/b);
Write ('x=',x);
End
Else
Begin
If (a=0) and (b=0)and (c<>0) then
write ('pas de solition');
If (a=0) and (b=0)and (c=0) then
Writeln('solution infini ');
If (a<>0) and (b<>0)and (c<>0) then
begin
d:=(b*b)-4*(a*c);
If (d=0)then
Begin
x:=-b+sqrt(d)/(2*a);
Writeln('solution double x=',x);
End
Else
Begin
x1:=-b+sqrt(d)/(2*a);
x2:=-b-sqrt(d)/(2*a);
writeln('deux solition defferentes');
write('x=',x1);
writeln('x=',x2);
End;
End;
End;
End.