and allows you to import any of your files in the future because module names become variable names inside python program (without the py)they should also follow the normal variable name rules outlined in for instanceyou can create module file named if pybut you cannot import it because if is reserved word--when you try to run import ifyou'll get syntax error in factboth the names of module files and the names of directories used in package imports (discussed in the next must conform to the rules for variable names presented in they mayfor instancecontain only lettersdigitsand underscores package directories also cannot contain platform-specific syntax such as spaces in their names when module is importedpython maps the internal module name to an external filename by adding directory path from the module search path to the frontand py or other extension at the end for instancea module named ultimately maps to some external file \ that contains the module' code other kinds of modules as mentioned in the preceding it is also possible to create python module by writing code in an external language such as cc++and others ( javain the jython implementation of the languagesuch modules are called extension modulesand they are generally used to wrap up external libraries for use in python scripts when imported by python codeextension modules look and feel the same as modules coded as python source code files--they are accessed with import statementsand they provide functions and objects as module attributes extension modules are beyond the scope of this booksee python' standard manuals or advanced texts such as programming python for more details module usage clients can use the simple module file we just wrote by running an import or from statement both statements findcompileand run module file' codeif it hasn' yet been loaded the chief difference is that import fetches the module as wholeso you must qualify to fetch its namesin contrastfrom fetches (or copiesspecific names out of the module let' see what this means in terms of code all of the following examples wind up calling the printer function defined in the prior section' module py module filebut in different ways module coding basics