Someone just asked me this question, but I'm a C # programmer, and I only know about class inheritance ... Interestingly, this thing is only for C / C ++? Is inheritance a reference a reference, we create a ClassA, and a ClassB inherited from this ClassA? Actually, what is it?
===== Change to make it clear:
Here is the question my friend got and he was doing a C programming test:
"There are two types of inheritance: inheritance by value and inheritance by reference. Show how to design a class to implement inheritance by reference"
So, I suppose this should be related to C / C ++ ... But I have never heard of inheritance by value and inheritance by reference. But, as Bn said in the message, I only heard about passing by value and passing by reference ... Or maybe I'm wrong? Because I'm a C # programmer, so I really don't know about C / C ++ stuff ...
thanks
source share