Question: Using the classes designed in Programming Exercises 10 and 11, write a program to simulate a bookstore. The bookstore has two types of customers: Those
Using the classes designed in Programming Exercises 10 and 11, write a program to simulate a bookstore. The bookstore has two types of customers: Those who are members of the bookstore and those who buy books from the bookstore only occasionally. Each member has to pay a $10 yearly membership fee and receives a 5% discount on each book purchased.
For each member, the bookstore keeps track of the number of books purchased and the total amount spent. For every eleventh book that a member buy, the bookstore takes the average of the total amount of the last 10 books purchased, applies this amount as a discount, and then resets the total amount spent to 0.
Write a program that can process up to 1000 book titles and 500 members. Your program should contain a menu that gives the user different choices to effectively run the program; in other words, your program should be user dri


The output should look similar to the screen shot below

The book data is provided in a file called BookData.txt and is ordered as follows. Each book element is stored as one line in the file Ch10_Ex12: Submit only: Example Data Data Element The number of books in the file. (up to 2 Header files (bookType.h, memberType.h) Implementation files (bookTypeImp.cpp, memberTypeImp.cpp) Your main program, and your documentation files. 1000 1 book) Title (1st book) ISBN 1% book) Publisher Name (1s: book) Published Year (1st book) Cost of Book (1 book) Copies on Hand (1* book) Count of Authors (1 book) Authors [up to 4 The Reason For Air 5-17-525281-3 BJ Smith & Co. 2016 45.00 15 The bookType header file must contain the following functional prototypes: void setBookInfolstring title, string ISBN, string Publisher, int PublishYear string auth, double cost, int copies, void setBokTitlefstring s); void setBookISBN(string s) void setBookPrice(double cost); void setcopiesInStock(int noOfCopies); (2nd book) Title (2nd book) ISBN 2nd book) Publisher Nane (2nd book) Published Year 2nd book) Cost of Book 2nd book) Copies on Hand (2nd book) Count of Authors (2nd book) Authors (4 Max) Fester Bestertester Joe Blowinski WTF Programmin 1-23-456789-3 Fly By Night Publishi 2014 25.87 10 void printinfo) onst bool isISEN(string s) const: bool isTitle(string s) const bool isAuthor(string s) snst void getBokTitle(string& s) sonsti void getBookISBN(string& s) const; double getBookPrice) const: Fester Bestertester loe Blowinski John Q. Public Sarah Smith E bool isIntk soast; void makeSale) void printBookPrice) const; void printbookTitle) const: void printbaskTitlAndISENO sonsti void updateduantity int addBooks); bookType)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
