First, you need the derivative of 1/(1+x): (-1)n(n!/(1+x)n+1) for the nth derivative.
The continuity condition means that you must exclude x = -1 in the interval a to b. The function and all derivatives are monotonic between a and b, so the maximum absolute value of the second derivative for a,b > -1 will be at a (the closest point to -1, making the fraction the largest). The Trapezoidal rule error is
E < (b-a)3/12n2 * (2/(1+a)3) solving for n:
n = sqrt((b-a)3/((1+a)3)6E))
Solve for n plugging in (0,2) for (a,b) and 10-5 for E
Do the same thing for Simpson's Rule.
Good luck!