मराठी

The access specifier that is applicable in case of inheritance is:

Advertisements
Advertisements

प्रश्न

The access specifier that is applicable in case of inheritance is:

पर्याय

  • default

  • private

  • public

  • protected

MCQ
Advertisements

उत्तर

protected

Explanation:

The protected modifier allows class variables and methods to be hidden from the general public while remaining fully visible and accessible to any subclass (child class) that inherits from it, even if that subclass resides in a completely different package.

shaalaa.com
  या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?
पाठ 6: Encapsulation - Exercises [पृष्ठ १४८]

APPEARS IN

रूपा पंडित Computer Applications [English] Class 10 ICSE
पाठ 6 Encapsulation
Exercises | Q 1. (v) | पृष्ठ १४८
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×