st or es items months figure the sales data viewed as collection of spreadsheets each spreadsheet contains the sales for specific store and is divided into rows and columns where each row contains the sales for one item and the columns contain the sales for each month since the storeitemand month numbers are all composed of consecutive integer values starting from we can easily represent each by unique index that is one less than the given number for examplethe data for january will be stored in column the data for february will be stored in column and so on likewisethe data for item number will be stored in row the data for item number will be stored in row and so on we leave the actual extraction of the data from text file as an exercise but for illustration purposeswe assume this step has been completed resulting in the creation and initialization of the - array as shown heresalesdata multiarray total sales by store with the data loaded from the file and stored in - arraywe can produce many different types of reports or extract various information from the sales data for examplesuppose we want to determine the total sales for given storewhich includes the sales figures of all items sold in that store for all months the following function computes this valuecompute the total sales of all items for all months in given store def totalsalesbystoresalesdatastore )subtract from the store since the array indices are less than the given store