Ask Question

Name:
Title:
Your Question:

Answer Question

Name:
Your Answer:
User Submitted Source Code!


Description:
  sssss
Language: PASCAL
Code:
program diskriminat; 
var a,b,c,x,x1,x2,d:real; 
begin 
writeln('enter a,b,c,'); 
readln (a,b,c); 
d:=B*B-4*A*C; 
writeln ('D=',D:6:2); 
IF D>0 then begin x1:= -b +sqrt(d)/2*a;  
x2:=-b-sqrt(d)/2*a;  
writeln ('X1=',x1:6:2);writeln('x2=',x2:6:2) 
end else IF D<0 then writeln ('kornei net')
else begin x:=-b/2*a;
writeln ('x=', x:6:2) end;
Readln
end.
Comments: