If a base class has a bunch of overloaded constructors, and
an inherited class has another bunch of overloaded
constructors, can you enforce a call from an inherited
constructor to an arbitrary base constructor?
Answer Posted / js_m
yes, for example
class Root
{
public Root(int id) {...}
}
class Derived
{
public Derived (int id) : base(id)
{}
}
'public Derived (int id) : base(id)' does the need ful.
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
Why do we use abstraction in c#?
What is difference between managed and unmanaged code?
Can list contain duplicates c#?
What are the problem with .NET generics?
What is unmannaged code and will CLR handle this kind of code or not .
What is difference between static and constant variable?
2. What happened when BO object has been called?
What are different types of classes in c#?
What is the use of 0 in c#?
What does namespace mean?
What is the use of delegates in c#?
What can I create with c#?
Explain about c# language.
What is the use of main method in c#?
Explain the steps to create satellite assembly?