OPPs
OPPs
a.
Data members
b.
Member functions
c.
Static data allowed
d.
Public access specifier
.
Which among the following can show polymorphism?
a.
Overloading ||
b.
Overloading +=
c.
Overloading <<
d.
Overloading &&
A.
A. explicit
B. public
C. implicit
D. private
A. class
B. object
C. function
D. none of these
b) Dot operator
c) Arrow operator
d) Dot or arrow as
required
View Answer
Answer: d
28. Which feature
of OOP reduces
the use of nested
classes?
a) Inheritance
b) Binding
c) Abstraction
d) Encapsulation
View Answer
Answer: a
29. Which
keyword among
the following can
be used to declare
an array of
objects in java?
a) allocate
b) arr
c) new
d) create
View Answer
Answer: c
b) Dot operator
c) Arrow operator
d) Dot or arrow as
required
View Answer
Answer: d
28. Which feature
of OOP reduces
the use of nested
classes?
a) Inheritance
b) Binding
c) Abstraction
d) Encapsulation
View Answer
Answer: a
29. Which
keyword among
the following can
be used to declare
an array of
objects in java?
a) allocate
b) arr
c) new
d) create
View Answer
Answer: c
b) Dot operator
c) Arrow operator
d) Dot or arrow as
required
View Answer
Answer: d
28. Which feature
of OOP reduces
the use of nested
classes?
a) Inheritance
b) Binding
c) Abstraction
d) Encapsulation
View Answer
Answer: a
29. Which
keyword among
the following can
be used to declare
an array of
objects in java?
a) allocate
b) arr
c) new
d) create
View Answer
Answer: c
29. Which
keyword among
the following can
be used to declare
an array of
objects in java?
a) allocate
b) arr
c) new
d) create
View Answer
Answer: c
29. Which keyword among the following can be used to declare
an array of objects in java?
a) allocate
b) arr
c) new
d) create
……………………………………………………………………………………
What is friend
member functions
in C++?
a) Non-member
functions which
have access to all
the
members
(including private)
of a class
b) Member
function which
doesn’t have
access to private
members
c) Member
function which
can modify any
data of a class
d) Member
function which
can access all the
members of a
class
View Answer
Answer: a
What is friend
member functions
in C++?
a) Non-member
functions which
have access to all
the
members
(including private)
of a class
b) Member
function which
doesn’t have
access to private
members
c) Member
function which
can modify any
data of a class
d) Member
function which
can access all the
members of a
class
View Answer
Answer: a
What is friend member functions in C++?
a) Non-member functions which have access to all the
members (including private) of a class
b) Member function which doesn’t have access to private
members
c) Member function which can modify any data of a class
d) Member function which can access all the members of a
class
………………………………………………………………………………….
Instance of which
type of class can’t
be created?
a) Parent class
b) Abstract class
c) Anonymous
class
d) Nested class
Instance of which type of class can’t be created?
a) Parent class
b) Abstract class
c) Anonymous class
d) Nested class
……………………………………………………………………………….
When a base class is privately inherited by derived class public members of the base class can
only be accessed by the ……… of the derived class.
A) non-member functions
B) friend functions
C) member functions
D) class members
…………………………………………………………………………………………..
16. In ……………………. inheritance, the constructors are executed in the order of
inheritance.
A) multipath
B) multiple
C) multilevel
D) hierarchical
……………………………………………………………………………………………..
17.The member functions of a derived class can directly access only the ……………….. data.
A) private and protected
B) private and public
C) protected and public
D) private, protected and public
18.The friend functions and the member functions of a friend class can directly access the
………………. data.
A) private and protected
B) private and public
C) protected and public
D) private, protected and public
……………………………………………………………………………………….
In C++, ……………………. creates objects, even through it was not defined in the class.
A) default constructor
B) parameterized constructor
C) implicit constructor
D) copy constructor
……………………………………………………………………………………….
An ………………….. with a constructor or destructor cannot be used as a member or a union.
A) class
B) object
C) function
D) variable