Question: please slove quickly use c++ Problem 3 (30 pts) A book normally has attributes like a title, number of pages, and a genre Horror, or
Problem 3 (30 pts) A book normally has attributes like a title, number of pages, and a genre "Horror", or "Sci-Fic"). You own 3 horror books and 5 sci-fi books. You decided to place a bookshelf in your room where it will hold your book collection. Your bookshelf can hold a maximum of 20 books, no more. Given the description above, please do the following: Create a Book class with its attributes, getters/setters functions. Optionally, you may include any suitable functions. o Create Book_Shelf class that is an array of objects for class books with the following methods: oint CountBooksByGenre(string genre). This function counts the number of books by a given genre. oint Count TotalBooks(). This function counts how many Books the Bookshelf has. oint CountRemaining Slots(). This function counts the number of free slots at the Bookshelf given that the maximum Bookshelf slots will be 20. o Test your code from your main function to create the objects for the classes, and to test the methods of the Bookshelf class and to display the results. Look up this URL for assistance: C++ array of objects: CodesDope
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
