Fill an array of 15 elements with random integers from the range from 0 to 40.

Fill an array of 15 elements with random integers from the range from 0 to 40. Print the array to the screen and find the sum of the array elements, the minimum element of the array and the number of numbers greater than 10

program zz1;
const n = 15;
var i, s, k, min: integer; // set variables of integer type
m: array [1..n] of integer;
begin
for i: = 1 to n do // write numbers in the array at random
m [i]: = random (41);
for i: = 1 to n do // display the array on the screen
write (m [i], ”);
writeln; // go to a new line to display the response
min: = 10000;
for i: = 1 to n do
begin
s: = s + m [i];
if m [i] <min then min: = m [i];
if m [i]> 10 then k: = k + 1;
end;
writeln (‘the sum of all array elements =’, s);
writeln (‘minimum array element =’, min);
writeln (‘the number of array elements greater than 10 =’, k);
end.



One of the components of a person's success in our time is receiving modern high-quality education, mastering the knowledge, skills and abilities necessary for life in society. A person today needs to study almost all his life, mastering everything new and new, acquiring the necessary professional qualities.