Question: 212 Write a program that simulates inventory bins in a warehouse. Each bin holds a number of the same type of parts. The program should
212 Write a program that simulates inventory bins in a warehouse. Each bin holds a number of the same type of parts. The program should use a structure that keeps the following data .Description of the part kept in the bin Number of parts in the bin The program should have an array of 10 bins, initialized with the following data: Part Description Valve Number of Parts in the Bin 10 Bearing Bushing Coupling Flange Gear Gear Housing Vacuum Gripper 15 21 Cable t Rod 25 18 12 The program shoold haye the following functions: - AddParts: a that increases a specifie bin's part count by a specified number RemoveParts: unction that decreases a specific bin's part count by a specified number when the program runs, it should repeakeep that perfrms the fullowing steps. The user should see a list of what each bin holds and how many parts are in each bin. The user can choose to either quit the program or select a bin. When a bin is selected, the user can eiher add parts to it or remove parts from it. The loop then repeats, showing the updated bin datg on the screen Input Validation: No bin can hold more than 30 parts, so dop't let the user add more than a bin can hold. Also, don't accept negative values for the number of parts being added or remoyed! 212 Write a program that simulates inventory bins in a warehouse. Each bin holds a number of the same type of parts. The program should use a structure that keeps the following data .Description of the part kept in the bin Number of parts in the bin The program should have an array of 10 bins, initialized with the following data: Part Description Valve Number of Parts in the Bin 10 Bearing Bushing Coupling Flange Gear Gear Housing Vacuum Gripper 15 21 Cable t Rod 25 18 12 The program shoold haye the following functions: - AddParts: a that increases a specifie bin's part count by a specified number RemoveParts: unction that decreases a specific bin's part count by a specified number when the program runs, it should repeakeep that perfrms the fullowing steps. The user should see a list of what each bin holds and how many parts are in each bin. The user can choose to either quit the program or select a bin. When a bin is selected, the user can eiher add parts to it or remove parts from it. The loop then repeats, showing the updated bin datg on the screen Input Validation: No bin can hold more than 30 parts, so dop't let the user add more than a bin can hold. Also, don't accept negative values for the number of parts being added or remoyed
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
