use ctrl- (on unixor ctrl- (on windowsto exit herethe first line saves value by assigning it to variable (lumberjack)which is created by the assignmentand the last two lines typed are expressions (lumberjack and * )whose results are displayed automatically againto exit an interactive session like this and return to your system shell prompttype ctrl- on unix-like machinesand ctrl- on windows in the idle gui discussed latereither type ctrl- or simply close the window notice the italicized note about this on the right side of this listing (staring with "#herei'll use these throughout to add remarks about what is being illustratedbut you don' need to type this text yourself in factjust like system and python promptsyou shouldn' type this when it' on system command linethe "#part is taken as comment by python but may be an error at system prompt nowwe didn' do much in this session' code--just typed some python print and assignment statementsalong with few expressionswhich we'll study in detail later the main thing to notice is that the interpreter executes the code entered on each line immediatelywhen the enter key is pressed for examplewhen we typed the first print statement at the promptthe output ( python stringwas echoed back right away there was no need to create source code fileand no need to run the code through compiler and linker firstas you' normally do when using language such as or +as you'll see in later you can also run multiline statements at the interactive promptsuch statement runs immediately after you've entered all of its lines and pressed enter twice to add blank line why the interactive promptthe interactive prompt runs code and echoes results as you gobut it doesn' save your code in file although this means you won' do the bulk of your coding in interactive sessionsthe interactive prompt turns out to be great place to both experiment with the language and test program files on the fly experimenting because code is executed immediatelythe interactive prompt is perfect place to experiment with the language and will be used often in this book to demonstrate smaller examples in factthis is the first rule of thumb to rememberif you're ever in doubt about how piece of python code worksfire up the interactive command line and try it out to see what happens for instancesuppose you're reading python program' code and you come across an expression like 'spam! whose meaning you don' understand at this pointyou can spend minutes wading through manualsbooksand the web to try to figure out what the code doesor you can simply run it interactively how you run programs