InterviewSolution
Saved Bookmarks
| 1. |
If a constructor is defined in protected access, then?(a) It’s instance can be created inside the subclasses(b) It’s instance can be created anywhere in the program(c) It’s instance can be created inside the subclasses and main() function(d) It’s instance can be created inside the parent class onlyI have been asked this question in an interview for internship.I need to ask this question from Protected Access Specifier topic in section Access Specifiers of Object Oriented Programming |
|
Answer» Right option is (a) It’s instance can be created INSIDE the subclasses |
|