CLS
DIM i, j AS INTEGER
DIM nRow, nCol AS INTEGER
nRow = 3
nCol = 3
DIM b(nRow, nCol) AS INTEGER
b(0, 0) = 1
b(0, 1) = 1
b(0, 2) = 2
b(1, 0) = -1
b(1, 1) = -4
b(1, 2) = 2
b(2, 0) = 2
b(2, 1) = -8
b(2, 2) = -100
DIM Summ(nCol)
FOR i=0 TO nCol-1
Summ(i)=0
FOR j=0 TO nRow-1
IF b(j,i) < 0 THEN
Summ(i) = Summ(i) + b(j,i)
END IF
NEXT j
PRINT Summ(i)
NEXT i