Duck typing and (java) interface concept
问题 I just read the Wikipedia article about duck typing, and I feel like I miss an important point about the interface concept I used to in Java: "When I see a bird that walks like a duck and swims like a duck and quacks like a duck, I call that bird a duck." class Duck: def quack(self): print("Quaaaaaack!") def feathers(self): print("The duck has white and gray feathers.") def swim(self): print("Swim seamlessly in the water") class Person: def quack(self): print("The person imitates a duck.")