?Interface1[] intt = new Interface1[] { new Dog("dddddd") }; ??????????? for (int i = 0; i < intt.Length; i++) ??????????? { ??????????????? intt[i].GGG(); ??????????? }
?Interface1[] intt = new Interface1[] { new Dog("dddddd") }; ??????????? for (int i = 0; i < intt.Length; i++) ??????????? { ??????????????? intt[i].GGG(); ??????????? }
2017-10-18
?Interface1[] intt = new Interface1[] { new Dog("dddddd") };
??????????? for (int i = 0; i < intt.Length; i++)
??????????? {
??????????????? intt[i].GGG();
??????????? }
?interface Interface1
??? {
??????? void GGG();
??? }
?class Dog : Pet,Interface1
{
?public void GGG()
??????? {
??????????? Console.WriteLine("爬樹");
??????? }
}
?Interface1[] intt = new Interface1[] { new Dog("dddddd") };
??????????? for (int i = 0; i < intt.Length; i++)
??????????? {
??????????????? intt[i].GGG();
??????????? }