DIM x(3, 2)
FOR i = 1 TO 3
FOR j = 1 TO 2
INPUT "vvedite element ", x(i, j)
NEXT
NEXT
PRINT "matrica"
FOR i = 1 TO 3
FOR j = 1 TO 2
PRINT x(i, j); " ";
NEXT
PRINT
NEXT
INPUT "vvedite a", a
INPUT "vvedite b (b>a)", b
FOR i = 1 TO 3
FOR j = 1 TO 2
IF x(i, j) >= a AND x(i, j) <= b THEN s = s + x(i, j)
NEXT
NEXT
PRINT "s="; s
Тестирование выполнено в программе QB64 ( Скачать )