Пожалуйста, прочтите новое правило об ограничении использования AI-инструментов. ×

Блог пользователя shivamisation

Автор shivamisation, история, 3 года назад, По-английски

I've been facing this issue for a long time , whenever there is an infinite loop in my code , my system freezes and I have to restart my system EVEN DURING CONTESTS . Is there a way to stop this , I am using Linux Mint distro and Geany IDE . Any suggestions will be highly appreciated .

  • Проголосовать: нравится
  • +16
  • Проголосовать: не нравится

»
3 года назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

I also have linux, but use Vscode with this extension to run test cases (https://marketplace.visualstudio.com/items?itemName=DivyanshuAgrawal.competitive-programming-helper). Which will automatically terminate your program if its run infinitely with returning the error of SIGTERM.

»
3 года назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

You can change running command with timeout. Read here: Timeout Command

»
3 года назад, # |
  Проголосовать: нравится -8 Проголосовать: не нравится

I don't think mint 20.2 have this issue anymore. What is your version ?