title: PyQt5 : How to make a button close the gui after clicking
body: <p>Here is my code for the click button:</p>
  
  <pre><code>run_btn=QtWidgets.QPushButton("Run")
  def main():
      print ('Starting Program')
  run_btn.clicked.connect(main)
  </code></pre>
  
  <p>But after I click "Run", it just prints "Starting Program" again and again, and the GUI window doesn't disappear:</p>
  
  <p><img src="https://i.stack.imgur.com/TB6T5.png" alt="screenshot"></p>
  
  <p>How can I make the button print it once and go on with the program ?</p>
  
  <p><strong>I am using PyQt5 and Python 3.4.0</strong></p>