Python Programming for Raspberry Pi, Sams Teach Yourself in 24 Hours

(singke) #1
FIGURE 3.6 An IDLE script tip.


  1. Finish the Python statement by typing "This is my first Python
    statement in IDLE"). Look at your Python statement and make sure it reads
    print ("This is my first Python statement in IDLE"). If you
    do not have it correct, then modify it by using the left- and right-arrow keys and the
    Delete key. When you are sure it is correct, press Enter. You should see output
    similar to what is displayed in Figure 3.7. Congratulations! You just correctly
    entered your first Python statement in IDLE.


FIGURE 3.7 Output from a Python statement in IDLE.


  1. Finally, exit the IDLE shell by pressing the key combination Ctrl+Q. The IDLE
    interactive mode window should close.


Did You Know: Exiting IDLE
You can leave the IDLE shell a couple different ways. As you did in step 9,
you can use the key combination Ctrl+Q to exit. Also, you can use the menu
options in IDLE to leave: To do so, click the File menu and then select Exit.
Free download pdf