0
0
Hãy luôn nhớ cảm ơn và vote 5*
nếu câu trả lời hữu ích nhé!
Program BTT;
Uses crt;
Var x,y,z: extended;
Begin
Clrscr;
Write('Nhap x, y: '); Readln(x,y);
If sqr(x)+sqr(y)<=1 then Z:=sqr(x)+sqr(y);
If (sqr(x)+sqr(y)>1) and (y>=1) then Z:=x+y;
If (sqr(x)+sqr(y)>1) and (y<x) then Z:=0.5;
Write('Z = ',Z:0:2);
Readln
End.
Hãy giúp mọi người biết câu trả lời này thế nào?
uses crt;
var x, y, Z : real;
begin
clrscr;
write('Nhap so x, y = '); readln(x, y);
if x * x + y * y <= 1 then Z := x * x + y * y;
if (x * x + y * y > 1) and (y >= 1) then Z := x + y;
if (x * x + y * y > 1) and (y < x) then Z := 0.5;
write('Z = ', Z : 2 : 1);
readln
end.
Hãy giúp mọi người biết câu trả lời này thế nào?
Bảng tin