Answers to Quiz 2

Understanding object-oriented programming is easy.     Image

Explanation: Object-oriented programming is a very advanced concept and is often misunderstood by experienced programmers. Despite what some may say, understanding OOP isn’t easy. Remember this when you’re frustrated.

1.    Why is inheritance the cornerstone of OOP?

Inheritance enables polymorphism, which is the main reason object-oriented languages exist.

2.    Consider the following figure:

Image

If class B inherits class A, which already imported the definition of class C, why ...

Get AdvancED ActionScript 3.0: Design Patterns now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.