Question: Goals: Developing problem-solving skills, using functions and arrays Problem: You have been asked to use your programming skills to help analyze data from a company
9:17 AM Project 4 Project 4-Fall18.pdf CMPSC 201 Fall 2018 To be done individually Worth 55 points total Due by 11:00 pm on 11/16/18 Geals: Developing problem-solving skills, using functions and arrays Preblem: You have been asked to use you programming skills to help analyne data from a company name Resistors-R-Us This compamy has different locations peoducing resisiors wih difSerent formulas. They have automated the data colloction so that the resistances are stoeed in a Eile containing a table (2-D array Each row of the table rapecsents a specific formulation and each column represents a specific company location Your program should have a main function and 4 other functions as described below. The company has stated that there will not be more than 80 foemulations and not more than 10 locations using the same formulations One function should open the file "Resistons-R-Us dai and read the first line that contains the number of formulations (the first valuc) and number of locations (the second valuc) uing those formulations Using these twe values, your function should then read the rest of the data and store the values in a 2-dimensional array with formulations in rows and the locations in columns As the resistances are being stored, a message should be output if any resistance is not in the range of 3 to 35 inclusive and the number of resistances not in the range shoeld be counted. The message should ouput the resistance, the location and the formulation as the cxample below The value of 2-9427 ohns fron location 1 for formulation auapec The resistance should still be stored in the array. The 2-dimensional array, the mumber of formulatioes and the number locations should be sent back to the function call Thhe number of resistances not in the range of 3 ohms to 35 ohms inclusive should be returned to the function One function should accept the 2-dimensional array, the number of Sormulations and number of locations then create a l-dimensional array containing the minimum resistances for each formulation and create a 1-dimensional anray containing the maximom resistances for each formulation. This function should call the function to output a 1-dimensional anray once for the minimam and once for the maximum values befoee sending these arrays back to the function call One function should accept the 2-dimessional array and determine the average resistance for each formulation. The average resistance for each formulation should be calculated without including the maximum and minimum resistance for that formulation, therefore this function will to call the function that calculales formulatioe The averape resistances for the formulations should be stored in another I- dimensional array which is sent back to the function call Programming Project4 CMPSC 201 Fall 2018 One function that will the number Dashboard Calendar To Do Notifications Inbox
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
