If term 1 is a_{1}, then, for an arithmetic series a_{n} = (n-1)d + a_{1} . The sum of the a's from 1 to n will be na_{1} + (1+2+3+...n-1) d. This last expression can be written as na_{1} + (n-1)(n)/2 * d = S_{n}

In this case, S_{n} = -20, a_{1} = 25 and d = -6. This leads to a quadratic in n. (I get n = 10)