What am I doing wrong when I run your program I get

Subscript out of range (I put it up to 50) ...Then

Overflow.

Try mine I've used the data from the link in a data statement.

CLS

DATA 1,19,143,607,1789,4211,8539

'DATA 5,0,1,20,69,160,305

n = 7

DIM h(10, 10)

FOR i = 1 TO n

READ y(i)

NEXT i

z(1) = y(1)

FOR m = n - 1 TO 1 STEP -1

k = k + 1

diff(k) = z(1)

FOR i = 1 TO m

z(i) = y(i + 1) - y(i)

NEXT i

FOR i2 = 1 TO m

y(i2) = z(i2)

NEXT i2

NEXT m

k = 1

FOR i = 1 TO n

IF i > 2 THEN k = k * (i - 1)

diff(i) = diff(i) / k

IF diff(i) = 0 THEN 10

NEXT i

10 f(1) = 1

FOR j2 = 1 TO i - 3

FOR j1 = 1 TO j2

ff(j1) = ABS(f(j1)) * j2 + ABS(f(j1 + 1))

NEXT j1

FOR j1 = 1 TO j2 + 1

IF j1 MOD 2 = 0 THEN f(j1 + 1) = ff(j1) ELSE f(j1 + 1) = -ff(j1)

h(j2, j1) = f(j1)

NEXT j1

NEXT j2

FOR i8 = 1 TO i

h(0, i8) = 1

NEXT i8

coeff(1) = diff(1)

kk = 1

FOR i8 = 0 TO i - 3

FOR i7 = 1 TO i - 2

x1 = x1 + diff(i7 + 1 + i8) * h(i7 - 1 + i8, i7)

NEXT i7

kk = kk + 1

coeff(kk) = x1

x1 = 0

NEXT i8

FOR g = 1 TO kk

PRINT coeff(g); "x^"; g - 1

NEXT g