1/10: This code should create two classes, then print a fact.
Create the Bird
class first.
if let eagle = bird as? Eagle {
}
class Eagle: Bird { }
var wingspan: Double? = nil
}
let bird = Bird()
} else {
print("This eagle has an unknown wingspan.")
print("The eagle's wingspan is \(wingspan).")
class Bird {
}
if let wingspan = eagle.wingspan {
Link copied to your pasteboard.