Exemple #1
0
 static void Main(string[] args)
 {
     RealDuck rd = new RealDuck();
     IShoutable shou = rd;
     shou.Shut();
     rd.Swim();
 }
Exemple #2
0
        static void Main(string[] args)
        {
            RealDuck   rd   = new RealDuck();
            IShoutable shou = rd;

            shou.Shut();
            rd.Swim();
        }