class am
{
public void show()
{
System.out.print("\nshow");
}
}
class B extends am
{
public void in()
{
System.out.print("\nin");
}
}
public class Aaa {
public static void main(String[] args) {
am m=new am();
B n=new B();
m.show();
n.in();
n.show();
}
}
output:
show
in
show
{
public void show()
{
System.out.print("\nshow");
}
}
class B extends am
{
public void in()
{
System.out.print("\nin");
}
}
public class Aaa {
public static void main(String[] args) {
am m=new am();
B n=new B();
m.show();
n.in();
n.show();
}
}
output:
show
in
show
No comments:
Post a Comment
SAY HELLO!!