abstract class Demo {
public void show()
{
System.out.println("Hello I am In show method of Abstract
class");
}
}
class Sample extends Demo
{
public void show()
{ super.show();
System.out.println("Hello I am In Sample ");
}
}
public class Test
{
public static void main(String[] args) {
//I WANT TO CALL THE METHOD OF BASE CLASS IT IS POSSIBLE OR NOT
CAN WE USE SCOPE RESOLUTION OPERATOR TO CALL OR JAVA NOT
SUPPORTED THAT :: OPERATORE
}
}
Answer Posted / sathiya
We cant call the base class since we cant create object for
abstract class(base class is a abstract class).
And java does not support the scope resoultion operator to
call a class.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How do you use compareto?
Is main is a keyword?
Is there a sort function in java?
Why string is called as immutable?
What are access specifiers available in java?
What is a linkedhashmap java?
Write a program to check for a prime number in java?
What is class level lock ?
What is abstraction in java?
Is class forname reflection?
What is the generic class?
Can a class with private constructor be extended?
Can we write a class without main method in java?
What is the use of string and stringbuffer?
What kind of variables a class can consist of?