Var
R1,R2,R3,R:real;
begin
read(R1,R2,R3);
R:=R1*R2/(R1+R2)+R2*R3/(R2+R3);
write(R:2:2);
end.
Var i, n, sum: integer;
begin
writeln('Введите степень');
read(n);
sum := 1;
for i := 1 to n do
sum := sum * 9;
writeln(sum);
end.
Прога А на ABCPaskal^
Progaram sdaef;
var S, i: real;
label cikl;
S:=0;
i:=10;
if i>5 then begin
cikl:
S:=S+i;
i:= i-1
If i> 5 then goto cikl;
else
writeln (S);
end;
end.
2. Найти сумму чисел массива в переменной Sum, а потом:<span> </span>
<span>Writeln('Сумма элементов массива чётное число = ', not odd(Sum));</span>
1.
<span>var</span> m<span>:</span><span>array</span><span>[</span><span>1</span>..<span>100</span><span>]</span><span>of</span><span>integer</span>;
i<span>,</span>a<span>,</span>n<span>:</span><span>integer</span>;
<span>begin</span><span>write</span><span>(</span><span>'Введите размерность массива: '</span><span>)</span>;<span>readln</span><span>(</span>n<span>)</span>;
<span>write</span><span>(</span><span>'Введите число А: '</span><span>)</span>;<span>readln</span><span>(</span>a<span>)</span>;
<span>writeln</span><span>(</span><span>'Введите массив: '</span><span>)</span>;
<span>for</span> i<span>:=</span><span>1</span><span>to</span> N <span>do</span><span>readln</span><span>(</span>m<span>[</span>i<span>]</span><span>)</span>;
<span>writeln</span><span>(</span><span>'Массив: '</span><span>)</span>;
<span>for</span> i<span>:=</span><span>1</span><span>to</span> N <span>do</span>
M<span>[</span>i<span>]</span><span>:=</span>m<span>[</span>i<span>]</span><span>-</span>a;
<span>for</span> i<span>:=</span><span>1</span><span>to</span> N <span>do</span><span>write</span><span>(</span>M<span>[</span>i<span>]</span><span>,</span><span>' '</span><span>)</span>;
<span>end</span>.
Var x:real;
begin
x := -4;
while x <= 4 do begin
writeln('x=',x : 2 : 2,' y=', abs(x-2)+abs(x+1) : 2 : 2);
x := x + 0.5;
end;
readln; //задержка ввода
end.