Question: Here's the second run that uses the inventory.dat created by the first program run: Welcome to Trish's Inventory Input System Current Inventory: Item name

Here's the second run that uses the inventory.dat created by the first program run:

 

Welcome to Trish's Inventory Input System

Current Inventory:

Item name      Count  Unit Cost  Description

---------      -----  ---------  -----------

Comic Book        23        4.50 Vintage graphic novels

Cook Book         11       15.99 Delicious recipes

Math Book          9       22.33 First year math textbook

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 1

 

Enter the item name: Python Basics

Enter the item count: 20

Enter the unit cost: 35.00

Enter the description: Tome of invaluable knowledge

Python Basics added to inventory.

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 2

 

Enter item name: Romance Novel

Romance Novel: Not found

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 2

 

Enter item name: Python Basics

Python Basics

      Count: 20, Cost: 35.0

      Tome of invaluable knowledge

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 4

 

Item name      Count  Unit Cost  Description

---------      -----  ---------  -----------

Comic Book        23        4.50 Vintage graphic novels

Cook Book         11       15.99 Delicious recipes

Math Book          9       22.33 First year math textbook

Python Basics     20      35.00  Tome of invaluable knowledge

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 3

 

Enter item name: Romance Novel

Romance Novel: Not found

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 3

 

Enter item name: Cook Book

Cook Book deleted.

 

What would you like to do?

(1) Add an item

(2) Display an item

(3) Delete an item

(4) Display all inventory

(0) Exit

Enter your choice: 0

 

Final Inventory:

Item name      Count  Unit Cost  Description

---------      -----  ---------  -----------

Comic Book        23        4.50 Vintage graphic novels

Math Book          9       22.33 First year math textbook

Python Basics     20      35.00  Tome of invaluable knowledge

 

Inventory.dat file was created.

 

 

NOTE: It is not required to have the output for displaying the inventory to be aligned, however aligning those fields may result in up to 10 extra points being applied to your grade! You can assume that the item name will be no larger than 14 characters, the item count will be less than 1000, and the unit cost will stay under $1000.00.



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 Programming Questions!