Question 41Asked in UGC NET Computer Science, November 2017 (Paper II & III, Selected Questions)

A member function can always access the data in ______ , (in C++)

  1. Athe class of which it is member
  2. Bthe object of which it is a member
  3. Cthe public part of its class
  4. Dthe private part of its class
Show answerHide answer

Correct answer: (A) the class of which it is member

Explanation

A member function can always access all the data (public, private and protected) of the class of which it is a member.

From UGC NET Computer Science PYQ, November 2017 (Paper II & III, Selected Questions)

This is question 41 of UGC NET Computer Science PYQ, November 2017 (Paper II & III, Selected Questions). See all questions of this paper with answers, or attempt the paper as a timed online test to get your score and all-India rank.