A mortgage is taken out for $80000. It is to be paid by annual installments of $5000 with the first payment being made at the end of the first year that the mortgage is taken out. Interest of 4% is then charged on any outstanding debt. Find the total time taken to pay off the mortgage. Please explain in details.