Anyone tell me how to add pause feature in quiz app?

hello friend i have made quiz app .i have added timer but i want to add feature pause system to stop quiz if user has not completed quiz and move out from quiz then if user again play quiz then jump that position when user had paused the quiz please help

You don’t need to pause the clock! When user left the app, simply record the time in TinyDB, and when quiz syarted again, start counting from the value saved in DB.