Can you have a constructor in abstract class?
Answer Posted / saurabh
public class xyz : abc
{
int r = 10;
public xyz()
{
r = 35;
}
}
public abstract class abc
{
public int i = 0;
public abc()
{
i = 10;
}
}
sure , we can create constructor in abstract class.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the exact difference in between unicast and multicast object? Where we will use?
Implement a stack with push (), pop() and min() in O(1) time.
In Java list the methods that can be overridden?
What modifiers are allowed for methods in an interface?
Is java ee a framework?
What is a boolean in java?
Where and how can you use a private constructor?
What is re-factoring in software?
Can I overload to string method
List down the methods and interfaces of collection class in java.
What is variable explain with example?
What is better- service oriented or batch oriented solutions?
Explain about version control?
What is the maximum size of a string in java?
What is set string?