| для нахождения максимального значения
| для нахождения минимального значения
|
в каждой строке
| FOR i = 1 TO n
MAX = A(i,1)
K = 1
FOR j = 2 TO m
IF A(i,j) > MAX THEN
MAX=A(i):K= j
END IF
NEXT j
B(i) = MAX
NEXT i
| FOR i = 1 TO n
MIN = A(i,1)
L = 1
FOR j = 2 TO m
IF A(i,j) < MIN THEN
MIN=A(i,j):L= j
END IF
NEXT j
B(i) = MIN
NEXT i
|
в каждом столбце
| FOR j = 1 TO m
MAX = A(1,j)
K = 1
FOR i = 2 TO n
IF A(i,j) > MAX THEN
MAX=A(i):K= i
END IF
NEXT i
B(j) = MAX
NEXT j
| FOR j = 1 TO m
MIN = A(1,j)
L = 1
FOR i = 2 TO m
IF A(i,j) < MIN THEN
MIN=A(i,j):L= i
END IF
NEXT i
B(j) = MIN
NEXT j
|