Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please help !! Write a C++ program to display the following menu 1.Add Book 2. Search Book 3, Borrow Book 4. Display Book Information *5.

Please help !! image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
Write a C++ program to display the following menu 1.Add Book 2. Search Book 3, Borrow Book 4. Display Book Information *5. Exit If user in selects 1, system will allow the user to add three books to the library. For each book input, title, author name and isbn. If the user selects 2, the system will ask for a book title for searching and display "Found" if the book title is one of the books titles inputted in option 1 otherwise, displays "Not found". If the user selects 3, the system asks the user to input book's title for borrowing. If the book title is one of the three books inputted in option 1, the system should let the user borrow the book and display "borrowed successfully! otherwise, the system should display "Not available" or "Sorry the book is already borrowed". If the user selects 4 the system will print book title, author name and isbn for each book with their availability information. . . . . The program shows the above menu continually, until the user inputs 5 for exit. Note: Please submit your code only in a doc or a pdf file. Other format .cpp or.sln, etc) will cause Zero Sample1 of the output *MAIN MENU** 1. Add Book 2. Search Book ***3, Borrow Book 4. Display Book Info *5. Exit **8*4 888833833388*8888 Enter your choice HERE->1 Enter book title to add: Introduction C++ Enter Author Name: Sara Smith Enter book title to add: Introduction to Java Enter Author Name: John Mark Enter ISBN: 2324581345679 Enter book title to add: Introduction to Python Enter Author Name: Lee Sami Enter ISBN: 6543987655555 Done! Sample2 of the output: *MAIN MENUse 1. Add Book 2. Search Book *3. Borrow Book 4. Display Book Info *5. Exit **8*4 888**8838833388*838888 Enter your choice HERE->2 Enter book title to search: Introduction to C++ Introduction to C++ is available! Sample3 of the output: ***MAIN MENU *1. Add Book 2. Search Book 3. Borrow Book *4. Display Book Info 5. Exit Enter your choice HERE-> 2 Enter book title to search: Programming C++ Programming C++ is NOT available! Sample4 of the output: *MAIN MENU 1. Add Book 2. Search Book 3. Borrow Book 4. Display Book Info 5. Exit 409** ** Enter your choice HERE-> 3 Enter book title to borrow: Introduction C++ Introduction C++is available! Please returned the book after two weeks form the checkout date Sample5 of the output: 1. Add Book 2. Search Book **3. Borrow Book 4. Display Book Info *45. Exit 8*83333 Enter your choice HERE->3 Enter book title to search: Introduction C++ Introduction C++ is NOT available! Sorry the book is already borrowed. Sample6 of the output: ***MAIN MENU* 1. Add Book 2. Search Book 3. Borrow Book 4. Display Book Info 5. Exit 4 944*444444449999999 Enter your choice HERE->4 Book Title: Introduction to C++ Author Name: Sara Smith ISBN: 2134533447896

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

SQL Server Query Performance Tuning

Authors: Sajal Dam, Grant Fritchey

4th Edition

1430267429, 9781430267423

More Books

Students also viewed these Databases questions

Question

1. What is the difference between exempt and nonexempt jobs?pg 87

Answered: 1 week ago

Question

Advance warning and an explanation for the layoff.

Answered: 1 week ago