using System;
class BaseClass
{
public BaseClass()
{
Console.WriteLine
("BaseClass");
}
}
class DerivedClass : BaseClass
{
public DerivedClass()
{
Console.WriteLine
("DerivedClass");
}
}
class MainClass
{
static void Main()
{
DerivedClass sample
= new DerivedClass();
/* 出力値
* BaseClass
* DerivedClass */
}
}
0 コメント:
コメントを投稿