Classes and Objects Questions and Answers Pdf - 1

Question: 1

______ type of constructor helps to create objects with different initial values.

(A) Parameterized

(B) Default

(C) Empty

(D) None of these

Ans: A

Parameterized

Question: 2

If an object is declared within a function then it is called

(A) Local object

(B) Global object

(C) Either A or B

(D) None of these

Ans: A

Local object

Question: 3

The members of the class are by default

(A) Public

(B) Private

(C) Protected

(D) None of these

Ans: B

Private

Question: 4

_____ are needed to represent real-world entities that not only have data type properties but also have associated operations,

(A) Arrays

(B) Classes

(C) Structures

(D) All the above

Ans: B

Classes

Question: 5

Objects are also called as ______ of class.

(A) Attributes

(B) Instant

(C) Instance

(D) None of these

Ans: C

Instance

Question: 6

______ objects can be used by any function in the program.

(A) Local object

(B) Global object

(C) Either A or B

(D) None of these

Ans: B

Global object

Question: 7

A constructor can be defined in _______ section of a class.

(A) Public

(B) Private

(C) Either Private or Public

(D) None of these

Ans: C

Either Private or Public

Question: 8

______ constructor is used to creating an array of objects.

(A) Overloaded

(B) Parameterized

(C) Default

(D) None of these

Ans: C

Default

Question: 9

When Member function defined outside the class using ______ operator.

(A) Scope resolution

(B) Reference

(C) Conditional

(D) Membership

Ans: A

Scope resolution

Question: 10

Objects are also called as

(A) Instance of class

(B) Class

(C) function

(D) scope

Ans: A

Instance of class