Skip to content

Instantly share code, notes, and snippets.

@takuma7
Created December 16, 2011 02:24
Show Gist options
  • Save takuma7/1484140 to your computer and use it in GitHub Desktop.
Save takuma7/1484140 to your computer and use it in GitHub Desktop.
class Bird{
void showName(){
System.out.println("鳥の名前を表示します。");
}
void about(){
System.out.println("特徴や習性を表示します。");
}
}
class Kestrel extends Bird{
void showName(){
System.out.println("田か木はやぶさか");
}
void about(){
System.out.println("");
}
}
class Merlin extends Bird{
void showName(){
System.out.println("");
}
void about(){
System.out.println("");
}
}
class Dictionary{
void showBird(Bird bird){
bird.about();
}
}
class Mondai15_1{
public static void main(String[] args){
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment