CameraIcon
CameraIcon
SearchIcon
MyQuestionIcon


Question

In $$C++$$, a function contained within a class is called a.


A
In built function
loader
B
User defined function
loader
C
Member function
loader
D
None of these
loader

Solution

The correct option is D Member function

In C++, a function contained within a class is called a Member function.

Member functions are operators and functions that are declared as members of a class. Member functions do not include operators and functions declared with the friend specifier. These are called friends of a class. We can declare a member function as static; this is called a static member function.

A member function of a class is a function that has its definition or its prototype within the class definition like any other variable. It operates on any object of the class of which it is a member, and has access to all the members of a class for that object.



Mathematics

Suggest Corrections
thumbs-up
 
0


similar_icon
Similar questions
View More


similar_icon
People also searched for
View More



footer-image