Question: Write te code in c++ language Write a program that checks the quality of the products coming from a production line using a function. For

 Write te code in c++ language Write a program that checks

Write te code in c++ language

Write a program that checks the quality of the products coming from a production line using a function. For each product, there is a compound whose quantity must be CLOSE to its ideal value. However, due to manufacturing problems this quantity varies from product to product First, the program will read the number of products (numProd) as an int. Then, the ideal value of the compound will be given (idealval) as a double followed by the tolerance level (tollevet) as a double Lastly, one by one the quantity of the critical compound for each item will be given as souble values. The program will check the critical compound value of each product using a function (isQuantityAcceptable) that gets necessary items as parameters and returns a bool value. The main function will print out the index of the "defective items as int values. An item that is OUTSIDE the tolerance boundary is a "defective item" The tolerance boundary can be calculated with the following formulas: Lower Boundary-idealval - (idealval tollevel) Upper Boundary=idealval + (idealval tollevel) NOTE: The quantity acceptability check MUST be done in the function. And printing the result to the screen MUST be done in the main function. NOTE The index number of the first product is 1, NOTO. 5 10 0.10 nput 59.8 9.5 11.2 10.1 89.5 0.12 6 105 0.20 99.9 10.2 8.2 12 11 102 98 110 105 104 130 79.5 Output 14 4567

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!