Can we create instance for Abstract class?
Answer Posted / manjit
abstract class aa {
public abstract void main(String[] args);
}
class aaa {
public static void main(String[] args)throws Exception{
Object x = Class.forName("aaa").newInstance();
System.out.println(x);
}
}
Try the above program and be amazed and shocked!
Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
Explain how to implement an object pool in c#.net
What is the difference between var and dynamic types in c# 4.0?
i want o/p 011242110 in c# code.
What is a multi line comment?
What is static classes in c#?
Which of these string definitions will prevent escaping on backslashes in c#?
What is the difference between dynamic and var in c#?
What is difference between assembly and namespace?
What does void do in c#?
What is Covariance and contravariance in C#?
What is command object in c#?
what is main function of alternate teamplate of datalist?
Why do we need to call CG.SupressFinalize?
How do partial classes work in c#?
Define satellite Assembly in .NET?