継承
概要
既存クラスを継承した、ユーザー定義クラスの作り方。
参照
前提条件
手順
手順というか、参照サイトのコード丸写し。
class Person
{
public string name; // 名前
public int age; // 年齢
}
class Student : Person
{
public int id; // 学籍番号
}
class Person
{
public string name; // 名前
public int age; // 年齢
}
class Student : Person
{
public int id; // 学籍番号
}
atwikiでよく見られているWikiのランキングです。新しい情報を発見してみよう!
最近アクセスの多かったページランキングです。話題のページを見に行こう!