title: How to exit a script in Spyder?
body: <p>I am using <a href="http://winpython.sourceforge.net/" rel="nofollow noreferrer">WinPython</a>'s Spyder. When I am creating a new script with the command <code>exit()</code>, and run it there, this command kills the kernel:</p>
  
  <blockquote>
    <p>It seems the kernel died unexpectedly. Use 'Restart kernel' to continue using this console.</p>
  </blockquote>
  
  <p>What's the right way to stop a script in this runtime environment?</p>