Const e=0.001;
var a1,a2:real;n:integer;
begin
a1:=0.5;
a2:=sin(a1)/cos(a1)/2;
n:=2;
writeln(n,a2:7:4);
while abs(a2-a1)>=e do
begin
a1:=a2;
a2:=sin(a1)/cos(a1)/2;
n:=n+1;
writeln(n,a2:7:4);
end;
writeln('n = ',n);
end.
Результат:
2 0.2732
3 0.1401
4 0.0705
5 0.0353
6 0.0177
7 0.0088
8 0.0044
9 0.0022
10 0.0011
11 0.0006
n = 11