I made this project because I usually fall asleep at night before I get things done, and I hate it.
This project works by checking the system idle time (the period with no user input) every 100ms. If the idle time exceeds 300s, it will play the alarm sound at max volume and prompt an equation problem. You need to solve it to turn off the alarm. After that, the alarm repeat the idle check