program FP uses CRT var integer IP IL real array 100 of real array 100

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
program FP;
uses CRT;
var a,b,i,n:integer;
h,IP,IL:real;
x:array[0..100] of real;
y:array[0..100] of real;
begin
a:=0;b:=1;n:=100;IL:=0;
h:=(b-a)/n;
writeln('h=',h);
for i:=0 to n do begin
x[i]:=a+i*h;
{writeln('x[',i,']=',x[i]);} end;
for i:=0 to n do
begin
y[i]:=sqrt(1+sqr(x[i]));//формула
writeln('y[',i,']=',y[i]);
if i<n then IL:=h*y[i]+IL;
end;
writeln('IL=',IL);
readln();
end.