exam(elaborations)Polymorphism and Abstract Classes in java
1. Explain the difference between the terms late binding and polymorphism . 2 . Suppose you modify the definitions of the class Sale ( Display 8.1 ) by adding the modifier final to the definition of the method bill . How would that change the output of the program in Display 8.3 ? 3. Would it be legal to add the following method definition to the class DiscountSale ? public static boolean isAGoodBuy(Sale theSale) { return (theSDiscount() 20); }
Document information
- Uploaded on
- February 7, 2023
- Number of pages
- 7
- Written in
- 2022/2023
- Type
- Exam (elaborations)
- Contains
- Questions & answers