In Chapter 2 of A Little Java, A Few Patterns, Question 22 is:
Are there only Onions on this Shish^D:
new Skewer()?
Answer is:
true, because there is neither Lamb nor Tomato on new Skewer().
Skewer is a subclass of Shish^D, Onion is also a subclass of Shish^D, I don't understand why there are onions on new Skewer()
, could someone explain this a bit further?
Aucun commentaire:
Enregistrer un commentaire