public void performQuack() { quackBehavior.quack(); } public void performFly() {…} } public class MallardDuck extends Duck { ! public MallardDuck() { quackBehavior = new Quack(); flyBehavior = new FlyWithNoWings(); } ! public void display() {…} } ࢭ㐰՟ḝෆᕌී⪠