terminating conditions and improving acuratey of timer