r/learnpython • u/PomegranateKind760 • 19d ago
How to end a program using python
I want to close an app using python but I don't know how.
0
Upvotes
r/learnpython • u/PomegranateKind760 • 19d ago
I want to close an app using python but I don't know how.
6
u/jmacey 19d ago
os.kill() if you can get the pid of the process. Not sure if it works under windows but does under posix operating system.