Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- abstract class AbstractClass
- {
- public abstract void show();
- }
- interface Interface
- {
- void show();
- }
- public class Test extends AbstractClass implements Interface
- {
- public void show()
- {
- System.out.println("my show method");
- }
- public static void main(String[] a)
- {
- AbstractClass ac = new Test();
- ac.show();
- Interface i = new Test();
- ac.show();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement