MCQHard1 mark
1
Choose the correct answers to the questions from the given options. (Do not copy the questions, write only the correct answers.)
Assertion (A): Static method can access static and instance variables. Reason (R): Static variables can be accessed only by static method.
Topic: Static and instance members
Previous-year question practice database
Try it
Pick an option and check your answer. The full worked answer is below either way.
Answer
Exam answer
(d) Assertion and Reason both are false..
Explanation
Both statements are false, and for opposite reasons. The assertion fails because a static method belongs to the class, not to any object, so it cannot touch instance variables directly — it would not know WHICH object’s copy to use. The reason fails because static variables can be accessed by instance methods too, not only by static ones. Test each half separately before choosing.
In words
Assertion and Reason both are false..
More from Encapsulation
Which of the following is NOT an access specifier?2026Post office is an example for __________ access specifier.2025The access specifier that gives least accessibility is __________.2024A mechanism where one class acquires the properties of another class:2023A method which is a part of a class rather than an instance of the class is termed as:2023The access modifier that gives least accessibility is:2022