Resources Status ti... Overview Plans Tollow-up , Lastly, one by one the viscosity for each bottle will be given as double values. The program will check the viscosity value of each bottle using a function (isViscosityAcceptable that gets necessary items as parameters and returns a bool value. The main function will prin out the index of the "valid items" as int values. An item that is WITHIN the tolerance boundar is a "valid item". The tolerance boundary can be calculated with the following formulas; Lower Boundary = idealvis - (idealvis * 2.2*tolLevel) Upper Boundary = idealvis + (idealvis * 1.2*tolLevel) NOTE: The viscosity 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 bottle is 1, NOTO. 5 10 0.10 Input 5 9.8 9.5 11.2 22.1 89.5 0.12 6 105 0.20 99.9 10.2 8.2 12 11 132 98 106 205 4 30 7 9.5 Output 234 123478 23 Answer assignment Tollow-up Participants Assignment Write a program that checks the viscosity of shampoo bottles coming from a production line using a function. For each bottle, the viscosity value must be CLOSE to its ideal value. However, due to manufacturing problems viscosity varies from bottle to bottle. First, the program will read the number of bottle (numBottle) as an int. Then, the ideal viscosity value will be given (idealvis) as a double followed by the tolerance level (tollevel) as a double. Lastly, one by one the viscosity for each bottle will be given as double values. The program will check the viscosity value of each bottle using a function (isViscosityAcceptable) that gets necessary items as parameters and returns a bool value. The main function will print out the index of the "valid items" as int values. An item that is WITHIN the tolerance boundary is a "valid item" The tolerance boundary can be calculated with the following formulas; Lower Boundary = idealvis - (idealvis * 2.2*tolLevel) Upper Boundary = idealvis + (idealvis * 1.2*tolLevel) NOTE: The viscosity 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 bottle is 1, NOTO. 5 10 0.10 89.5 0.12 6 105 0.20