1

Just wondering if there's a way to close the terminal with a python script in an if else statement. I know how to exit a program with "exit( 0 )" but is there a way to actually close the terminal, like when you hit "X" or Alt + F4?

Thanks! (I'm new to python so I don't know much, sorry.)

2
  • Close the terminal that python is running in or a separate terminal? Commented Jun 18, 2016 at 14:04
  • 1
    Did you try this? Commented Jun 18, 2016 at 14:22

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.