welp, i just answered my own question
Since we need to transform 13x^2+nx-17 into (ax+b)(cx+d), we know that 13x^2+nx-17=axcx+axd+bcx+bd.
ac=13, nx=axd+bcx=x(ad+bc) and -17=bd and n=ad+bc
Since 13 is prime, a or c has to be 13 or 1.
The same thing goes for bd, since -17 is prime, b has to be 17, 1, -1, or -17 and if b is 17, d has to be -1, if b is -17, d has to be 1, if b is 1, d has to be -17 and so on.
plugging a and c in makes it either
(x+b)(13x+d) or (13x+b)(x+d) and plugging b and d in makes it either
(x+17)(13x-1) or (x-17)(13x+1) or (x+1)(13x-17) or (x-1)(13x+17).
For (x+17)(13x-1), we can expand it to 13x^2+220x-17, therefore n can equal 220
For (x-17)(13x+1), we can expand it to 13x^2-220x-17, therefore n can equal -220
For (x+1)(13x-17), we can expand it to 13x^2-4x-17, therefore n can equal -4
For (x-1)(13x+17), we can expand it to 13x^2+4x-17, therefore n can equal 4
From this, we can see that n=220, -220, -4 or 4.