Page 111 - 2622_Delhi Police Public School_C-6
P. 111

Type the commands at the prompt, and you will immediately get the results. Simply type 3 + 3 and
                 press the Enter key. The prompt displays the number 6. Try more values and see what happens.



















                 Working in Script Mode

                 The Interactive Mode does not save the user's commands in the form of a program. The Script Mode
                 saves the user's commands in the form of a program. To understand the working of Script Mode, we
                 have divided the process into four parts. Let us discuss these.

                 Creating a New File

                 Open the Python IDLE window and follow these steps to create a new file:

                                  1   Click on the File
                                      menu.                                         Click on the New   2
                                                                                    File option.






















                 Writing a Program

                 Type the program code in Python window.




















                                                                                                         Python    109
   106   107   108   109   110   111   112   113   114   115   116