1.3 var a: word; begin readln(a); a := a div 100 * 10 + a mod 10; writeln(a); end. --------------------- var x, y: real; begin write('x = '); readln(x); if (x <= 0) then y := -x else if (x <= 1) then y := x else y := 1 / sqr(x); writeln('y = ', y); end. ----------------------- const n = 5;
var x, y, z: integer; begin for x := 1 to n do begin readln(y); if ((y < 0) and (z > -1)) then z := x - 1; end; writeln(); writeln(z); end.
1.3
var
a: word;
begin
readln(a);
a := a div 100 * 10 + a mod 10;
writeln(a);
end.
---------------------
var
x, y: real;
begin
write('x = ');
readln(x);
if (x <= 0) then
y := -x
else
if (x <= 1) then
y := x
else
y := 1 / sqr(x);
writeln('y = ', y);
end.
-----------------------
const
n = 5;
var
x, y, z: integer;
begin
for x := 1 to n do
begin
readln(y);
if ((y < 0) and (z > -1)) then
z := x - 1;
end;
writeln();
writeln(z);
end.