Question: 2. (50 pts] Write a C++ program that reads the following list of input data (book.dat) into an array of Book class objects. This program

 2. (50 pts] Write a C++ program that reads the following

list of input data (book.dat) into an array of Book class objects.

This program should allow users to search and view the books from

2. (50 pts] Write a C++ program that reads the following list of input data (book.dat) into an array of Book class objects. This program should allow users to search and view the books from a Menu with the following options: 1. List all available books 2. Search for book using A. Title or B. ISBN? 3. Exit Program The format of the file is as follows: // The title of the book // The ISBN of the book // The Book Publisher // The year it was published // The authors of the book // The cost of the book // The number of copies of the book // The number of authors // List of Authors. book.dat C++Programing: From Problem Analysis to Program Design 5-17-525281-3 ABC 2000 52.50 20 1 Malik, D.S. Fuzzy Discrete Structures 3-7908-1335-4 Physica-Verlag 2000 89.00 10 Malik, Davender 3 Mordeson, John Fuzzy Mathematic in Medicine 3-7908-1325-7 Physica-Verlag 2000 89.00 10 3 Mordeson, John Malik, Davender Cheng, Shih-Chung Harry John and The Magician 0-239-23635-0 McArthur A. Devine Books 1999 19.95 10 3 Goof, Goofy Pluto, Peter Head, Mark Dynamic InterWeb Programming 22-99521-453-1 GNet 1998 39.99 25 1 Dimitri P. Bertsekas h Use the following functions in your program driver program. //Function Reads the input data file void getBookData(Book books[], int& no0fBooks); //Function Displays the list of book information void printBookData(Book books[], int noofBooks); //Function Searches for book based on book title or ISBN void searchBookData (Book books[], int bookCount); //Function searches list of books based on book ISBN and I/returns the location (index) of the found book. void searchBookDataByISBN(Book books(), int bookCount, string ISBN, int& loc); //Function Searches for book based on book title or ISBN void searchBookData(Book books[], int bookCount); //Function searches list of books based on book ISBN and //returns the location (index) of the found book. void searchBookDataByISBN(Book books [], int book Count, string ISBN, int& loc); 4 CSC234 Advanced C++ Lab 2: Chapters 9-10 //Function searches list of books based on book title and //returns the location (index) of the found book. void searchBookDataByTitle(Book books[], int book Count, string title, int& loc); HINT: Define a class Book with all the data members and member functions for accessing and setting the data members. All data members should be private. No non-constant data should be declared globally

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