0

I made script for browser game. In this game, I am standing still and my script clicks on certain places bksononechno, but I need that if I clicked on the letter k This script would kill itself and not try to close the browser and its tab in the browser and something similar.

Sorry for mistakes.

Lahiru Mirihagoda
  • 1,113
  • 1
  • 16
  • 30
Vadimchik
  • 11
  • 2
  • `sys.exit(1)` in python program. `Ctrl+C` from running command line – bigbounty May 29 '19 at 10:44
  • You can take a look at [Python exit commands - why so many and when should each be used?](https://stackoverflow.com/questions/19747371/python-exit-commands-why-so-many-and-when-should-each-be-used). As mentioned, `sys.exit()` is the preferred one. – shriakhilc May 29 '19 at 10:45

1 Answers1

0

You can add sys.exit(1) in the program itself and do Ctrl-C in the command line.

chess_lover_6
  • 632
  • 8
  • 22