Instantly share code, notes, and snippets.

Embed
What would you like to do?
Circular reference 1
let person1 = Person(name: "🐱")
let person2 = Person(name: "🦁")
let person3 = Person(name: "🐷")
person1.normalHello()
person2.strongHello()
person3.weakHello()
//結果
--- init 🐱 ---
--- init 🦁 ---
--- init 🐷 ---
Hello, I am 🐱!
Hello, I am 🦁!
Hello, I am 🐷!
--- deinit 🐷 ---
--- deinit 🐱 ---
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment