What are the two access specifiers in C++ ?
Void and free
Public and private
Int and double
Formal and informal
Which of the following can access private data members or member functions of a class ?
Any function in the program
All global functions in the program
Any member function of that class
Only public member functions of that class
Which of the following statement is correct with respect to the use of friend keyword inside a class ?
A private data member can be declared as a friend
A class may be declared as a friend
An object may be declared as a friend
We can use friend keyword as a class name
What will be used when terminating a class ?
:
;
}
;;
How many copy of static data members can be created for the entire class ?
1
2
3
4
Which of the following argument is used to pass a copy of an entire object to the function ?
Pass by reference
Pass by value
Recursion
Setting a condition
Which of the following is used in the class name to declare an object ?
Type specifier
Class name
New
Scope resolution
Which term is used to represent a group of similar and related objects ?
Module
Function
Class
Composition
Which of the following keyword is used to control access to a class member ?
Default
Break
Public
Protected
Which of the following is also known as instance of class ?
Friend function
Object
Member function
Member variable