Short answer
No.
Work around
You could do on
- Windows use vbScripts
- Linux use bash scripts
- Android use a service / notifications
- MaC related products idk
with OS.execute()
something like
Example
sleep, 5000
run, awesome_game.exe
Correct Approach
Save the time when your application is closed and on open subtract the current time from the saved time then take appropriate actions