Why can?t you specify the accessibility modifier for methods
inside the interface?
Answer Posted / lakshmi
Methods that implement an interface must be declared public. The reason for this is that methods are implicitly public within an interface, so their implementation must also public. Also the return type and signature of the implementing method must match exactly the return type and signature specified in the interface definition.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is ienumerable and iqueryable?
How to override a function in c#?
In how many ways you can overload a method?
What is ilist c#?
What is mvc in c#?
How to open a new form on button click in Windows forms?
How can we make a thread sleep for infinite period ?
Explain About .Net remoting
What is desktop application testing?
Distinguish between the Debug class and Trace class with its functionality?
Is dictionary a collection?
What is asp net c# corner?
What is the use of expression tree in c#?
How many types of polymorphism are there?
What is float in unity?