Ответ:
Объяснение:
const
n = 100;
var
a:array[1..n] of integer;
i, k, d:integer;
begin
k:=1;
d:=1;
for i:= 1 to n do begin
a[i]:=k;
if (i = 50) then begin
d:=-1;
k:=k+1;
end;
k:=k + d;
for i:= 1 to n do
write(a[i], ' ');
readln;
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Ответ:
Объяснение:
const
n = 100;
var
a:array[1..n] of integer;
i, k, d:integer;
begin
k:=1;
d:=1;
for i:= 1 to n do begin
a[i]:=k;
if (i = 50) then begin
d:=-1;
k:=k+1;
end;
k:=k + d;
end;
for i:= 1 to n do
write(a[i], ' ');
readln;
end.