Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
task 1
Program n_1; const N = 10; var a: array[1..10] of integer; i, min, max:integer; begin min := 0; max := 0; randomize; write('Входной массив:'); for i := 1 to 10 do begin a[i] := random(10); write(a[i]:3); end; writeln; for i := 1 to 10 do begin if (a[i] > 0) and (a[i] mod 2 = 0) then begin if (min = 0) and (max = 0) then begin min := a[i]; max := a[i]; end else begin if a[i] < min then min := a[i] else if a[i] > max then max := a[i]; end end end; if (max=0) and (min=0) then writeln('нет нужных элементов') else writeln('Min = ', min, ', Max = ', max); end.
run
|
edit
|
history
|
help
0
DI
AAAXACAdxcd
Full join
test
StringCompare
sdfgjikjuyhtgrfed
How To Get Discord Nitro For Free
abc
Get Round of 5 c# Vishal
Intuit // C# // listing_4.2 (Converting / Parsing)