Ответ: type my_array = array[1..20] of integer;
procedure input_array(var c: my_array; n: integer);
begin
for var i:= 1 to n do
read(c[i]);
end;
procedure count_array(var c: my_array; n: integer);
var d: integer;
var x: real;
d:= d + c[i];
x:= d/n;
writeln(x);
var a: my_array;
var size: integer;
read(size);
input_array(a, size);
count_array(a, size);
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Ответ: type my_array = array[1..20] of integer;
procedure input_array(var c: my_array; n: integer);
begin
for var i:= 1 to n do
read(c[i]);
end;
procedure count_array(var c: my_array; n: integer);
begin
var d: integer;
var x: real;
for var i:= 1 to n do
begin
d:= d + c[i];
x:= d/n;
end;
writeln(x);
end;
begin
var a: my_array;
var size: integer;
read(size);
input_array(a, size);
count_array(a, size);
end.