Hello, OnlineGDB Q&A section lets you put your programming query to fellow community users. Asking a solution for whole assignment is strictly not allowed. You may ask for help where you are stuck. Try to add as much information as possible so that fellow users can know about your problem statement easily.

Create class Books

0 votes
asked Jun 14, 2019 by mark (220 points)
Create class Books, it should have private variable, title, size_h, size_w, number_of_pages and public variables year, author. Create also one public method getData() and constructor, which allows initialization of all variables of the class. In the main function, create two objects of the class. Use getData() method and return the title of the book, it’s height, width, number of pages, year of publishing (year) and author.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.
Welcome to OnlineGDB Q&A, where you can ask questions related to programming and OnlineGDB IDE and and receive answers from other members of the community.