1 2 3 ... 9 10
0 1 2 ... 8 9
0 0 1 ... 7 8
. . . ... . .
0 0 0 ... 0 1
CLS
n = 10
DIM a(n, n)
FOR i = 1 TO n
c = 0
FOR j = i TO n
c = c + 1
a(i, j) = c
NEXT
NEXT
FOR i = 1 TO n
FOR j = 1 TO n
PRINT a(i, j);
NEXT
PRINT
NEXT
Тестирование выполнено в программе QB64 ( Скачать )