Page 96 - Touchcode_C6_Flipbook
P. 96

Step 2:    Scroll down the list of programs and click on Python 3.12 folder.

                  Step 3:   Click on IDLE (Python 3.12 64-bit).

                  The main IDLE window appears. IDLE stands for Integrated Development and Learning
                  Environment. It is a code editor which helps you to write and execute Python programs in
                  the editor itself.

                  Working in Script Mode

                  The Interactive Mode does not save the commands entered by the user in the form of
                  a program. The Script Mode saves the commands entered by the user 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
                  Follow these steps to create a new file:

                  Step 1:   Open the Python IDLE window.

                  Step 2:   Click on the File tab. A drop-down menu appears.
                  Step 3:   Click on the New File option. A new editor window with a blank
                            file will appear on the screen.                                           Selecting New
                                                                                                        File option

                  Writing a Program
                  Type the program code in Python window.


                  print("Hello World!")

                  Saving Python Program
                  Follow these steps to save a Python program:

                  Step 1:   Click on the File tab.
                  Step 2:   Click on the Save option. The Save As dialog box appears.

                  Step 3:   Select the desired location to save the file.
                  Step 4:   Enter the name of the file in the File name box.
                  Step 5:    Click on Save button. The file will be saved by the given name at the selected location


                  Running a Python Program
                  Follow these steps to run a Python program:
                  Step 1:   Click on Run tab in the Menu bar.

                  Step 2:   Click on Run Module option.

                  The program will execute and the output will be shown in the Shell            Running a program
                  window.





                   94     Touchcode-VI
   91   92   93   94   95   96   97   98