Explore topic-wise MCQs in Testing Subject.

This section includes 657 Mcqs, each offering curated multiple-choice questions to sharpen your Testing Subject knowledge and support exam preparation. Choose a topic below to get started.

1.

In access control in a protected derivation, visibility modes will change as follows:

A. private, public and protected become protected
B. only public becomes protected
C. public and protected become protected
D. only private becomes protected
Answer» D. only private becomes protected
2.

Which of the following is correct about the statements given below? |. All operators can be overloaded in C++. ||. We can change the basic meaning of an operator in C++.

A. Only I is true.
B. Both I and II are false.
C. Only II is true.
D. Both I and II are true.
Answer» C. Only II is true.
3.

Data in an object oriented language is safe from accidental alternation as it is

A. buged
B. compressed
C. hidden
D. error free
Answer» D. error free
4.

Using operation or function in different ways depending what they are operating on is called

A. polymorphism
B. dimorphism
C. trimorphisim
D. automorphism
Answer» B. dimorphism
5.

At which point of time a variable comes into existence in memory is determined by its

A. Scope
B. Storage class
C. Data type
D. All of the above
Answer» C. Data type
6.

A Class is a user defined data-type which have data members and

A. data function
B. variable
C. member function
D. linear function
Answer» D. linear function
7.

A dictionary is example of data

A. object
B. entity
C. collection
D. types
Answer» D. types
8.

To access the public function fbase() in the base class, a statement in a derived class function fder() uses the statement

A. fbase();
B. fder();
C. base::fbase();
D. der::fder();
Answer» B. fder();
9.

The mechanism whereby the implementation details of a class are kept hidden from the user is called

A. data hiding
B. data declaration
C. data initialization
D. data determinant
Answer» B. data declaration
10.

Lines, rectangles and circles are

A. hardware objects
B. graphic objects
C. control system objects
D. circuit designing objects
Answer» C. control system objects
11.

Language which is historically procedural languages, but have been extended with some object oriented features is

A. Java
B. PHP
C. C
D. C++
Answer» C. C
12.

If we apply the brakes in a car, it will generally stop. 'STOP' is

A. attribute
B. behavior
C. constant
D. loop
Answer» C. constant
13.

Parameter which clarifies the relationship among program elements is

A. inheritant
B. base class
C. derived class
D. object
Answer» B. base class
14.

You separated a derived class name from its access specifier with

A. A colon
B. Two colons
C. Atleast one space
D. A semi colon
Answer» C. Atleast one space
15.

Member functions, when defined within the class specification:

A. are always inline
B. are not inline
C. are inline by default, unless they are too big or too complicated
D. are not inline by default
Answer» B. are not inline
16.

In object oriented language, single unit which has data and its function is termed as

A. attribute
B. object
C. constant
D. loop
Answer» C. constant
17.

If we want to modify the data we must know the data

A. member function
B. bit function
C. local function
D. linear function
Answer» B. bit function
18.

Subroutines or functions are the simplest form of

A. reuse
B. object
C. function
D. class
Answer» B. object
19.

The term __________ means the ability to take many forms.

A. Inheritance
B. Polymorphism
C. Member function
D. Encapsulation
Answer» C. Member function
20.

The wrapping of private data in classes in object-oriented programming languages is termed as

A. data encapsulation
B. data declaration
C. data initialization
D. data deletion
Answer» B. data declaration
21.

When a language has capability to produce new data types, it is said to be

A. declarable
B. extensible
C. initializable
D. detectable
Answer» C. initializable
22.

Member function will access data and return the value to user when it is

A. called
B. declared
C. initialized
D. deleted
Answer» B. declared
23.

Sending a message to the object is referred to as

A. calling the object
B. declaring the object
C. sending the object
D. initializing the object
Answer» B. declaring the object
24.

Attributes must contain specific

A. constant
B. loop
C. value
D. addition
Answer» D. addition
25.

The provision of a single interface to entities of different types is termed as

A. polymorphism
B. dimorphism
C. trimorphisim
D. automorphism
Answer» B. dimorphism
26.

Complex real object contains

A. attributes
B. variables
C. constants
D. strings
Answer» B. variables
27.

Defining the class

A. creates object
B. doesn't creates object
C. creates variable
D. creates function
Answer» C. creates variable
28.

If we want to read a data item in an object, member function in an object is

A. call
B. declare
C. initialize
D. delete
Answer» B. declare
29.

As functions do in procedural program, inheritance element shortens an

A. object oriented program
B. machine program
C. procedural program
D. structural program
Answer» B. machine program
30.

Components which communicates with each other by calling one another's member functions are

A. objects
B. members
C. bits
D. errors
Answer» B. members
31.

A struct is the same as a class except that

A. there are no member functions
B. all members are public
C. cannot be used in inheritance hierarchy
D. it does have a this pointer
Answer» D. it does have a this pointer
32.

Additional information sent when an exception is thrown may be placed in

A. the throw keyword
B. the function that caused the error
C. the catch block
D. an object of the exception class
Answer» D. an object of the exception class
33.

The operator

A. must be a member function
B. must be a non member function
C. can be both a & b above
D. cannot be overloaded
Answer» D. cannot be overloaded
34.

Which of the following is false for cin?

A. It represents standard input
B. It is an object of istream class
C. It is a class of which stream is an object
D. Using cin the data can be read from user’s terminal.
Answer» D. Using cin the data can be read from user’s terminal.
35.

In multiple inheritance

A. the base classes must have only default constructors
B. cannot have virtual functions
C. can include virtual classes
D. None of the above
Answer» D. None of the above
36.

Most important elements added in C to create C++ are

A. functions and loops
B. functions and classes
C. objects and classes
D. objects and functions
Answer» D. objects and functions
37.

Container of objects that are inserted and removed according to the last-in first-out principle is termed as

A. customized array
B. stack
C. binary tree
D. decimal tree
Answer» C. binary tree
38.

Stack in object oriented language can be referred to as data storage

A. constructs
B. entities
C. collection
D. types
Answer» B. entities
39.

Aircraft in an air traffic control system is

A. object
B. entity
C. collection
D. construct
Answer» B. entity
40.

Which of the following language designed mainly for object oriented programming, but with some procedural elements?

A. Java
B. PHP
C. Visual Basic
D. Matlab
Answer» B. PHP
41.

Attributes in the real world are equivalent to program's

A. data
B. function
C. module
D. loop
Answer» B. function
42.

The polymorphism can be characterized by the phrase

A. One interface,multiple methods
B. Multiple interfaces,one method
C. One interface,one method
D. None of the above
Answer» B. Multiple interfaces,one method
43.

User defined data types include

A. angle
B. integer
C. character
D. string
Answer» B. integer
44.

You may override the class access specifiers

A. Public members
B. Public and protected members
C. Any specific class members you choose
D. No class members
Answer» D. No class members
45.

To perform stream I/O with disk files in C++, you should

A. open and close files as in procedural languages.
B. use classes derived from ios.
C. use C language library functions to read and write data.
D. include the IOSTREAM.H header file.
Answer» C. use C language library functions to read and write data.
46.

If x = y,5 = 2 then x ∧ y equals________.(where ∧ is a bitwise XOR operator)

A. 00000111
B. 10000010
C. 10100000
D. 11001000
Answer» B. 10000010
47.

In C++, the range of signed integer type variable is ________

A. 0 to 2^16
B. - 2^15 to 2^15-1
C. -2^7 to 2^7-1
D. 0 to 2^8
Answer» C. -2^7 to 2^7-1
48.

The process of building new classes from existing one is called ______.

A. Polymorphism
B. Structure
C. Inheritance
D. Cascading
Answer» D. Cascading
49.

A variable defined within a block is visible

A. from the point of definition onward in the program.
B. from the point of definition onward in the function.
C. from the point of definition onward in the block.
D. throughout the function.
Answer» D. throughout the function.
50.

A pure virtual function is a virtual function that

A. has no body
B. returns nothing
C. is used in base class
D. both a and c
Answer» E.