const
m=5;
var
Z,B: array [1..m] of integer;
K,N,l,Qm1,i,j,max,nmax,ms: integer;
begin
for i:=1 to m do begin
write('Vvedite massy vagona ',i,'= ');
readln(Z[i]);
end;
N:=0;
for i:=1 to m do
if Z[i]>=60 then
begin
N:=N+1;
end;
writeln('chislo vagonov c massoj > ili =60t ',N);
K:=0;
for i:=1 to m do
if Z[i]>=60 then
begin
K:=K+Z[i];
end;
writeln('obshaja massa etix vagonov',' ',K);
l:=0;
for j:=1 to m do
if Z[j]>=60 then
begin
l:=l+1;
B[l]:=Z[j];
end;
Qm1:=0;
for i:=1 to m do
if Z[i]<=10 then
begin
writeln('nomer vagonov s massoj< ili =10 ', i);
Qm1:=Qm1+1;
end;
writeln('kol-vo vagonov s massoj < ili =10 ', Qm1);
for j:=1 to l do
{begin}
writeln(' ', B[j]);
max:=B[1];
nmax:=1;
{end;}
for i:=2 to N do
if max<B[i] then
begin
max:=B[i];
nmax:=i;
end;
writeln('samij tiagelij gryz v massive B', max:5, ' ' ,'ego nomer', i);
readln;
writeln; writeln; writeln {4tob text ne slivalsja }
end.
Блок-схема!, помогите сделать!) |