Question
This is a C++ question. I am supposed to write code to solve the following problem. Im used to code written in Visual Studio, therefor
This is a C++ question. I am supposed to write code to solve the following problem.
Im used to code written in Visual Studio, therefor im used to "using namespace std"
"Library"
Design and implement a Book class, to be used as part of software for a library. Class Book should have members for the ISBN, title, author, copyright date.Also store data on whether or not the book is checked out. Create functions for returning those values. Create functions for checking a book in and out. Do simple validation of data entered into a book,that is accept only ISBNs only of the form n-n-n-x where n is an integer and x is a digit or a letter. Store and ISBN as a string.
The add operators for the book class. Have the == operator check whether the ISBN numbers are the same for two books. Have the != also compare the ISBN number. Have a < Create an enumerated type for the Book class called Genre. Have the types be fiction,nonfiction,periodical,biography and children. Give each book a Genre and make appropritate changes to the Book constructor and member functions. Create a Patron class for the library, the class will have users name, library card numer and library fees (if owed). Gave functions that access this data, as well as function to set the fee of the user. Have a helper function that returns a Boolean depending on wheaterh or not the user owes a fee. Create a Library class. Include vectors of Books and Patrons. Include a struct called Transaction. Have it include a Book, a Patron and a Date (choose at random). Make a vector of Transactions. Create functions to add boooks to the library, add patrons to the library, and check out books. Whenever a user checks out a book, have the library make sure that both the user and book are in the library, if they are not, report an error. Then check to make sure the user does not owe any fees, if the user does, report an error. If not, create a Transaction and place it in the vector of Transactions. Also write a function that will return a vector that contains the names of all Patrons that owe fees. I really have no idea where to begin to solve this question.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started