Quit

Quit[]
terminates a Wolfram Language kernel session.

DetailsDetails

  • Quit[] quits only the Wolfram Language kernel, not the front end.
  • To quit a notebook front end, choose the Quit menu item.
  • All kernel definitions are lost when the kernel session terminates.
  • If you have kept the definitions in a file or in a notebook you can always reenter them in a subsequent session.
  • Before terminating a kernel session, the Wolfram Language executes any delayed value that has been assigned to the global variable $Epilog. Conventionally, this attempts to read in a file .m of commands to be executed before termination.
  • On most computer systems, Quit[n] terminates the Wolfram Language kernel, passing the integer n as an exit code to the operating system.
  • Exit is a synonym for Quit.

ExamplesExamplesopen allclose all

Basic Examples  (1)Basic Examples  (1)

Quit terminates the kernel, losing any definitions that have been made:

In[1]:=
Click for copyable input
Out[1]=

Quit[] will terminate the kernel. Do not enter it if you have any definitions you want to keep:

In[2]:=
Click for copyable input

The previous definition for a has been lost:

In[3]:=
Click for copyable input
Out[3]=
Introduced in 1988
(1.0)
| Updated in 2003
(5.0)