Answer Posted / dipal mehta
The above one is a right answer but the reader who reads it
for referance plz Note line :
I1 i1=new sample();
i1.add();
This might confusing but It means that We have created
object of I1 interface class but with sample as a assigned
object which is valic in this case.
Now call of i1.add() will call the method of interface I1
which points to or defined in Sample class
This will more clearer if you will append two or three more
simple methods like subtract() and try to call it as above
one which actually a part of Mostly used Multiple
Inheritance funda.
personally speaking it will benefitial to you if try
yourself
Hope readers like tips
Is This Answer Correct ? | 8 Yes | 2 No |
Post New Answer View All Answers
Explain the difference between managed and unmanaged code?
What is "common language specification" (cls) in .net?
How many types of design patterns available in .NET?
What is the use of common language runtime?
What is the difference between imperative and interrogative code?
How big is the datatype int in .net?
What is the advantage of .net?
How ccw (com callable wrapper) and rcw (runtime callable wrappers) works?
Explain what is the difference between web application and enterprise application?
What are Attributes in .NET?
What is meant by localization?
What are the similarities and difference between class and structure in .net?
What is the use com component in .net?
What are the differences between user control and server control?
What is cyclomatic complexity and why is it important?