Const
N = 3;
M = 4;
Var
T:array[1..N,1..M] of integer;
i,j:integer;
Begin
Randomize;
WriteLn('Было:');
For i:= 1 to N do
Begin
For j:= 1 to M do
Begin
T[i,j]:=random(3000);
Write(T[i,j]:6,' ');
if (99 < T[i,j])and(T[i,j]<1000)and(T[i,j] mod 7 = 0) then T[i,j]:=T[i,j]-10;<br> End;
WriteLn
End;
WriteLn('Стало:');
For i:= 1 to N do
Begin
For j:= 1 to M do
Write(T[i,j]:6,' ');
WriteLn
End;
End.
Было:
2280 893 1825 21
491 97 666 402
1961 2639 1873 1069
Стало:
2280 893 1825 21
491 97 666 402
1961 2639 1873 1069