user-defined modules as you learned earlierpython includes standard library containing modules of functions and class definitions that can be used in our programs by using modulesthe language itself can remain relatively small while still providing extended functionality structured programs python programs can quickly become very large and unmanageableespecially if the entire user code is placed within single source file to help structure and manage large programspython allows the user to create their own modules modulewhich is text file that contains python source code and has py extensioncan be used to group class definitions and related functions typicallya large program consists of top-level source file and one or more supplemental modules the top-level file acts as the driver which contains the statements for the main flow of executionand the modules contain related componentswhich act as tools that are imported and used as needed the code segment below illustrates the use of modules in organizing structured program it consists of three python source filesa top-level driver (grades py)and two supplemental modules (iomod pyand compmod py(notethis is small simple program used for illustration purposes in practicea short program like this would more likely be placed in single module grades py the driver module which contains the statements creating the main flow of execution import iomod import compmod gradelist iomod extractgrades(avggrade compmod computeaveragegradelist iomod printreportgradelistavggrade