Basically, we have
principal, P = 10,000
interest rate, i = 6% compounded annually = 0.06
Initial period = 5 years
At end of initial period,
Future value,
F = P(1+i)^5 (standard compound interest formula)
= 10000*(1.06)^5
= 13382.255776
For the next five years, the principal is
P=(13382.255776 - 4000)
=9382.255776
Future value after 5 more years, using again compound interest formula
F = P(1+i)^5
=9382.255776(1.06)^5
=12555.5746
Total amount of interest earned
= final amount less (initial amount - withdrawal)
= 12555.5746 - (10000-4000)
= 6555.5746
= 6555.57 (to the nearest cent)
For the final answer, round above to the nearest dollar as required by the question.