Question: Write a program that does these two tasks: Task 1 Create a file called inventory.txt that will save the following data: int serialNum; string
Write a program that does these two tasks:
Task
Create a file called "inventory.txt that will save the following data:
int serialNum;
string partName;
int quantity;
Ask the user to input inventory items until they enter an EOF character.
Please enter at least items into the inventory.txt file
Store this data in the file
Close the file
Task
In the same program, open the file for reading
Read the data that is in the file
Print the data to the console
Make sure there are headers and the output lines up under the headers
Close the file
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
