Class Library implements the interface Findable and has/should have the following members: - Instance variable Map books (maps the name of the book to the total number of pages in the book). - A constructor to initialize the instance variable. -Override method find (T obj) to search for books with total pages more than or equal to that of obj. Class Test has the main method. - main() method accepts inputs to instantiate an object of Library. For each book, the input.is accepted in the order-book name followed by the number of pages in the book.

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter10: Introduction To Inheritance
Section: Chapter Questions
Problem 20RQ
icon
Related questions
Question
Class Library implements the interface Findable and has/should have the following members:
- Instance variable Map<String, Integer> books (maps the name of the book to the total number of pages in the
book).
- A constructor to initialize the instance variable.
-Override method find (T obj) to search for books with total pages more than or equal to that of obj.
Class Test has the main method.
main () method accepts inputs to instantiate an object of Library. For each book, the input is accepted in the
order-book name followed by the number of pages in the book.
Transcribed Image Text:Class Library implements the interface Findable and has/should have the following members: - Instance variable Map<String, Integer> books (maps the name of the book to the total number of pages in the book). - A constructor to initialize the instance variable. -Override method find (T obj) to search for books with total pages more than or equal to that of obj. Class Test has the main method. main () method accepts inputs to instantiate an object of Library. For each book, the input is accepted in the order-book name followed by the number of pages in the book.
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Reference Types in Function
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,