Click here to Skip to main content
16,022,737 members
Please Sign up or sign in to vote.
1.86/5 (3 votes)
See more:
public class animal: dog
{
}
Posted
Updated 27-Dec-13 11:45am
v2
Comments
Sergey Alexandrovich Kryukov 27-Dec-13 22:12pm    
Nothing is really implemented. :-)
—SA

1 solution

It is backwards in its logic. A "dog" should inherit from a more general class such as "animal", not the other way around. However, there is not anything inherently wrong with that, other than it is not complete and we are not sure if the "dog" class that animal is inheriting even exists.
 
Share this answer
 
Comments
Member 10491035 27-Dec-13 18:37pm    
Thank you so much. I understood that clearly now
Richard C Bishop 30-Dec-13 10:01am    
You are welcome, come back anytime.
Sergey Alexandrovich Kryukov 27-Dec-13 22:12pm    
Correct, a 5. If you did not continue your explanation with "however", it would be really bad question, because we need to abstract out the semantics.
—SA
Richard C Bishop 30-Dec-13 10:01am    
Thank you Sergey!
Sergey Alexandrovich Kryukov 30-Dec-13 11:43am    
Sure. Happy New Year!
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900