===== PascalABC.NET =====
begin
var n := ReadInteger('n =');
var a := ArrRandom(n, -400, 400);
a.Println;
Writeln;
a.Transform(p -> (p > 0) and p.IsEven ? 0 : p);
a.Print
end.
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
===== PascalABC.NET =====
begin
var n := ReadInteger('n =');
var a := ArrRandom(n, -400, 400);
a.Println;
Writeln;
a.Transform(p -> (p > 0) and p.IsEven ? 0 : p);
a.Print
end.