Answered step by step
Verified Expert Solution
Question
1 Approved Answer
This is a MATLAB question. What are the answers for a) and b)? Thanks 2. (a) A technician is in charge of a store of
This is a MATLAB question. What are the answers for a) and b)? Thanks
2. (a) A technician is in charge of a store of electronic components and has the task of ordering more when stocks are low. The quantity of each component in the store is contained in a MATLAB matrix StockLevels. This matrix contains the component part number in the first column, and the quantity of parts remaining in the second column. For example, for only three components: StockLevels = [ 10341, 10342, 10343, 15; 21; 87 ] Write a script that helps the technician manage his task. It should ask for the component part number and the quantity of components being withdrawn from the store. The script should update the variable StockLevels with the new quantity of components and display a warning if the quantity of any component drops below 10. If a part number of -1 is entered, the script should end. (b) Explain the potential benefits of using a structure array instead of a matrix for storing data associated with the components and describe how a structure array could be implemented for the variable StockLevelsStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started