two using the python interpreter invoking the interpreter the python interpreter is usually installed as /usr/local/bin/python on those machines where it is availableputting /usr/local/bin in your unix shell' search path makes it possible to start it by typing the commandpython to the shell since the choice of the directory where the interpreter lives is an installation optionother places are possiblecheck with your local python guru or system administrator ( /usr/local/python is popular alternative location on windows machinesthe python installation is usually placed in :\program files\python \though you can change this when you're running the installer to add this directory to your pathyou can type the following command into the command prompt in dos boxset path=%path%; :\program files\python typing an end-of-file character (control- on unixcontrol- on windowsat the primary prompt causes the interpreter to exit with zero exit status if that doesn' workyou can exit the interpreter by typing the following commandquit(the interpreter' line-editing features include interactive editinghistory substitution and code completion on systems that support readline perhaps the quickest check to see whether command line editing is supported is typing control- to the first python prompt you get if it beepsyou have command line editingsee appendix interactive input editing and history substitution for an introduction to the keys if nothing appears to happenor if ^ is echoedcommand line editing isn' availableyou'll only be able to use backspace to remove characters from the current line the interpreter operates somewhat like the unix shellwhen called with standard input connected to tty deviceit reads and executes commands interactivelywhen called with file name argument or with file as standard inputit reads and executes script from that file second way of starting the interpreter is python - command [argwhich executes the statement(sin commandanalogous to the shell' - option since python statements often contain spaces or other characters that are special to the shellit is usually advised to quote command in its entirety with single quotes some python modules are also useful as scripts these can be invoked using python - module [argwhich executes the source file for module as if you had spelled out its full name on the command line when script file is usedit is sometimes useful to be able to run the script and enter interactive mode afterwards this can be done by passing - before the script on unixthe python interpreter is by default not installed with the executable named pythonso that it does not conflict with simultaneously installed python executable