More Classes
5th Class
6th Class
7th Class
8th Class
9th Class
10th Class
11th Class
12th Class
NAT I
NAT II
CSS
IQ
General Knowledge
MDCAT
ECAT
GAT General
GAT Subject
Other Links
Go to Home
Online Tests
MGT-301 Final Term Exams Preparation Virtual University MCQs With Answers
Question # 1
_______ is used to trace the logic of the program and correct the logical errors.
Choose an answer
Compiler
Editor
Linker
Debugger
Previous
Skip
Next
Question # 2
When a value is referred by a normal variable then it is known as,
Choose an answer
Direct Reference
Indirect Reference
Partial Reference
Proper Reference
Previous
Skip
Next
Question # 3
Class is a user defined___________.
Choose an answer
Data type
Memory referee
Value
None of the given options
Previous
Skip
Next
Question # 4
The programs, in which we allocate static memory, run essentially on ________
Choose an answer
Heap
System Cache
None of the given options
Stack
Previous
Skip
Next
Question # 5
What is the sequence of event(s) when deallocating memory using delete operator?
Choose an answer
Only block of memory is deallocated for objects
Only destructor is called for objects
Memory is deallocated first before calling destructor
Destructor is called first before deallocating memory
Previous
Skip
Next
Question # 6
Consider the following code segment. What will be the output of following code? Int addValue (int *a){ int b = (*a) + 2; return b ; } main () { int x =6 ; cout << x << “,” ; cout << addValue(&x) << “,” ; cout << x ; }.
Choose an answer
6,8,6
6,6,8
6,8,8
6,6,6
Previous
Skip
Next
Question # 7
Structure is a collection of ______________ under a single name.
Choose an answer
Only Functions
Only Variables
Both Functions and Variables
None of the given options
Previous
Skip
Next
Question # 8
Is used for ___________.
Choose an answer
calculation
reading
assigning value to variables
None of the given options.
Previous
Skip
Next
Question # 9
The number 544.53 must be stored in _____ data type.
Choose an answer
int
short
float (Sure)
char
Previous
Skip
Next
Question # 10
Overloaded delete operator function takes parameter of void pointer and returns.
Choose an answer
void
void pointer
pointer to an object
pointer of type int
Previous
Skip
Next
Question # 11
Classes defined inside other classes are called ________ classes.
Choose an answer
looped
nested
overloaded
none of the given options
Previous
Skip
Next
Question # 12
New and Delete are also used with ___________ and data types as well.
Choose an answer
Class, Objects
Structures, Pointers
Both Class and structures
None of above
Previous
Skip
Next
Question # 13
Which of the following option will be true, if we overload "-=" operator?
Choose an answer
only - operator needs to be overloaded
Minus (-) and = operators need to be overloaded
the -= operator need to be overloaded explicitly
the - and = operators need to be overloaded implicitly
Previous
Skip
Next
Question # 14
Header file: fstream.h includes the definition of the stream classes __________.
Choose an answer
ifstream, fstream, cout
ifstream, fstream, ofstream
fstream, cin, cout
None of the above
Previous
Skip
Next
Question # 15
Reference Value Type Data The code is written to __________ the program.
Choose an answer
implement
design
analysis
none of the given options
Previous
Skip
Next
Question # 16
Which of the following is correct way to initialize a variable x of int type with value 10?
Choose an answer
int x ; x = 10;
int x = 10;
int x, x = 10;
x = 10;
Previous
Skip
Next
Question # 17
NULL value has been defined in ______ and _________ header files.
Choose an answer
strings.h and iostream.h
ctype.h and conio.c
conio.c and conio.h
stdlib.h and stddef.h
Previous
Skip
Next
Question # 18
What purpose do classes serve?
Choose an answer
Data encapsulation
Providing a convenient way of modeling real-world objects
Simplifying code reuse
All of the given options
Previous
Skip
Next
Question # 19
The endl and flush are _______
Choose an answer
Functions
Operators
Manipulators
Objects
Previous
Skip
Next
Question # 20
The prototype of friend functions must be written ____ the class and its definition must be written ____.
Choose an answer
inside, inside the class
inside, outside the class
outside, inside the class
outside, outside the class
Previous
Skip
Next
Question # 21
In if structure the block of statements is executed only.
Choose an answer
When the condition is false
When it contain arithmetic operators
When it contain logical operators
When the condition is true
Previous
Skip
Next
Back