Ответ:
program test;
var c: array [1..15] of integer;
i: integer;
begin
randomize;
for i:=1 to 15 do
c[i]:=random(99)+1;
write(c[i]:4)
end;
writeln;
if c[i] mod 2 <> 0 then write(c[i],' ')
end.
var i: integer;
var C: array[1..15] of integer;
write('Массив: ');
for i := 1 to 15 do
C[i] := random(1, 99);
write(C[i], ' ');
writeln();
write('Нечётные элементы: ');
if C[i] mod 2 <> 0 then print(C[i]);
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Ответ:
program test;
var c: array [1..15] of integer;
i: integer;
begin
randomize;
for i:=1 to 15 do
begin
c[i]:=random(99)+1;
write(c[i]:4)
end;
writeln;
for i:=1 to 15 do
if c[i] mod 2 <> 0 then write(c[i],' ')
end.
Ответ:
var i: integer;
begin
var C: array[1..15] of integer;
write('Массив: ');
for i := 1 to 15 do
begin
C[i] := random(1, 99);
write(C[i], ' ');
end;
writeln();
write('Нечётные элементы: ');
for i := 1 to 15 do
if C[i] mod 2 <> 0 then print(C[i]);
end.