1. var x,a,s:real; i:integer; begin write('x = '); readln(x); a:=x; s:=x; i:=1; while i<11 do begin i:=i+2; a:=x*x*a; s:=a/i; end; writeln('s = ',s); end.
2. var x,a,s:real; i:integer; begin write('x = '); readln(x); a:=x; s:=x; i:=1; repeat i:=i+2; a:=x*x*a; s:=a/i; until i=11; writeln('s = ',s); end.
3. var x,a,s:real; i:integer; begin write('x = '); readln(x); a:=x; s:=x; for i:=1 to 11 div 2 do begin a:=x*x*a; s:=a/(2*i+1); end; writeln('s = ',s); end.
var x,a,s:real; i:integer;
begin
write('x = '); readln(x);
a:=x; s:=x; i:=1;
while i<11 do
begin
i:=i+2;
a:=x*x*a;
s:=a/i;
end;
writeln('s = ',s);
end.
2.
var x,a,s:real; i:integer;
begin
write('x = '); readln(x);
a:=x; s:=x; i:=1;
repeat
i:=i+2;
a:=x*x*a;
s:=a/i;
until i=11;
writeln('s = ',s);
end.
3.
var x,a,s:real; i:integer;
begin
write('x = '); readln(x);
a:=x; s:=x;
for i:=1 to 11 div 2 do
begin
a:=x*x*a;
s:=a/(2*i+1);
end;
writeln('s = ',s);
end.
Пример:
x = 3
s = 16104.2727272727