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
How will you make .NET programs work in Linux ?
Do you know what is garbage collector?
Tell us the difference between managed and unmanaged code?
What are the namespace available in .net?
Explain About GDI object ?
Please explain when should you use .net web forms over asp.net mvc?
What is singlecall activation mode used for in .net?
Explain about managed heap?
Is .net core free?
What is WSDL? Explain its architecture?
object is physical and class is logical..here class is not occupying any memory as our definition of class but i got a question then the class where it stores if it is not occupying any memory....
What is web.config in .net?
What are the two main parts of the .net framework?
What data providers available in .net to connect to database?
How to use datagrid value in select statements where condition ,if cell is hyperlink bounded column?