Quiz 1.10: Inheritance and composition
Q1: Inheritance and call dispatch
Given the following code snippet:
abstract type Foo end
struct Aaa <: Foo end
struct Bbb <: Foo end
struct Ccc end
foo(x::Foo) = println("Hello")
foo(x::Aaa) = println("Good day!")
foo(x) = print("Welcome!")Match the following commands with their corresponding outputs.