Economics homework help

Hello, I am trying to compute an answer to a question to get a better understanding and am having difficulty. What formula should be used? The question is asking for the amount of time (months and years)it would take to pay off a $180,000 loan at an APR of 10% if the person could pay $3,500 per month and then $4,000 per month.