Q:

Java - Abstract Class and Abstract Method

0

This Program is used to Abstract Class and Abstract Method concept.

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

// abstract class and abstract method demonstration 

abstract class one 
{ 
abstract void show1(); 

void show2() 
{ 
System.out.println("\nWelcome"); 
} 
} 

class two extends one 
{ 
void show1() 
{ 
System.out.println("\nHave a Nice Day"); 
} 
} 

class ssvAbstract1 
{ 
public static void main(String arg[]) 
{ 
two t = new two(); 
t.show1(); 
t.show2(); 
} 
}

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now