English

Name the access specifiers provided by Java.

Advertisements
Advertisements

Question

Name the access specifiers provided by Java.

Short Answer
Advertisements

Solution

  1. default: Visible to the package and to the objects
  2. private: Visible to the class only and not to the objects
  3. public: Visible to the world and to the objects
  4. protected: Visible to the package and all to subclasses and the objects
shaalaa.com
  Is there an error in this question or solution?
Chapter 6: Encapsulation - Exercises [Page 148]

APPEARS IN

Rupa Pandit Computer Applications [English] Class 10 ICSE
Chapter 6 Encapsulation
Exercises | Q 2. (ii) | Page 148
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×