file search rules do not apply because of thatyou must include both the py extension andif necessarythe full directory path leading to the file you wish to run for instanceto run file that resides in different directory from the one in which you are workingyou would typically list its full path ( python :\tests \spam pywithin python codehoweveryou can just say import spam and rely on the python module search path to locate your fileas described later use print statements in files yeswe've already been over thisbut it is such common mistake that it' worth repeating at least once here unlike in interactive codingyou generally must use print statements to see output from program files if you don' see any outputmake sure you've said "printin your file print statements are not required in an interactive sessionsince python automatically echoes expression resultsprints don' hurt herebut are superfluous typing unix-style executable scripts#our next launching technique is really specialized form of the priorwhichdespite this section' titlecan apply to program files run on both unix and windows today since it has its roots on unixlet' begin this story there unix script basics if you are going to use python on unixlinuxor unix-like systemyou can also turn files of python code into executable programsmuch as you would for programs coded in shell language such as csh or ksh such files are usually called executable scripts in simple termsunix-style executable scripts are just normal text files containing python statementsbut with two special propertiestheir first line is special scripts usually start with line that begins with the characters #(often called "hash bangor "shebang")followed by the path to the python interpreter on your machine they usually have executable privileges script files are usually marked as executable to tell the operating system that they may be run as top-level programs on unix systemsa command such as chmod + file py usually does the trick let' look at an example for unix-like systems use your text editor again to create file of python code called brian#!/usr/local/bin/python print('the bright side 'of life 'means concatenate for strings the special line at the top of the file tells the system where the python interpreter lives technicallythe first line is python comment as mentioned earlierall comments in python programs start with and span to the end of the linethey are place to insert extra information for human readers of your code but when comment such as the unix-style executable scripts#