AMD interview question

What is the difference between private and protected.

Interview Answer

Anonymous

15 Aug 2010

Private variables, are variables that are visible only to the class to which they belong. Whereas Protected are visible both class to which the belong as well as to its subclasses.