This program will keep track of both good and bad too small


This program will keep track of both good and bad (too small and too large) parts and ONLY STOP once the end of the file is found. A bearing is classified as faulty if its diameter is less than 1.96 mm or greater than 2.04 mm.

The program will also keep track of the average bearing diameter.

Each bearing should have a diameter of 2.00 mm with a tolerance of +/- 0.040 mm.

Program Requirements:

1. Reads data from a file until the end of the file is found.

2. Reports the size and number of the bearing read in for each bearing value in the file.

3. Reports the number of good, bad, and total bearings after reading in each bearing size (within the loop). ALSO reports the average diameter of the bearings examined.

4. After the end of the file is found (loop stops/stops reading in sizes):

a. Reports the total number of bearings, the number of good bearings, the number of bad bearings, and the average bearing diamtere for the batch as each bearing size is read into the program (each iteration).

b. After reading in all of the bearings the program reports:

i. Total number of bearings read

ii. Percentage of good ball bearings in the sample

iii. Percentage of bad ball bearings in the sample

iv. Average ball bearing diameter for the sample.

5. Includes comments througout the program describing what's happening.

C code with geany software

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: This program will keep track of both good and bad too small
Reference No:- TGS02900743

Expected delivery within 24 Hours