Var a:array [1..1000] of integer; k,i,n:integer; begin write ('kol-vo elementov v massive='); readln (n); write ('k=');readln (k); writeln ('vvedite massiv'); for i:=1 to n do readln (a[i]); write ('massiv: '); for i:=1 to n do write (a[i],' '); if (k<=n) and (k>0) then for i:=k+1 to n do a[i-1]:=a[i]; writeln; write ('massiv posle ydalenija: '); for i:=1 to n-1 do write (a[i],' '); end.
k,i,n:integer;
begin
write ('kol-vo elementov v massive=');
readln (n);
write ('k=');readln (k);
writeln ('vvedite massiv');
for i:=1 to n do
readln (a[i]);
write ('massiv: ');
for i:=1 to n do
write (a[i],' ');
if (k<=n) and (k>0) then
for i:=k+1 to n do
a[i-1]:=a[i];
writeln;
write ('massiv posle ydalenija: ');
for i:=1 to n-1 do
write (a[i],' ');
end.