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
The code is written to __________ the program.
Choose an answer
implement
design
analysis
none of the given options
Previous
Skip
Next
Question # 2
A template function must have
Choose an answer
One or more than one arguments
Only one argument
Zero arguments
None of the given options
Previous
Skip
Next
Question # 3
Skill(s) that is/are needed by programmer’s _______________________.
Choose an answer
Paying attention to detail
Think about the reusability
Think about user interface
All of the given options
Previous
Skip
Next
Question # 4
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 # 5
When we define an array of objects then
Choose an answer
Destructor will call once for whole array
Destructor will call for each object of the array
Destructor will never call
Depends on the size of array
Previous
Skip
Next
Question # 6
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 # 7
While calling function, the arguments are assigned to the parameters from _____________.
Choose an answer
left to right
right to left
no specific order is followed
none of the given options
Previous
Skip
Next
Question # 8
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
Question # 9
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 # 10
Which of the following is NOT a preprocessor directive?
Choose an answer
#error
#define
#line
#ndefine
Previous
Skip
Next
Question # 11
What does (*this) represents?
Choose an answer
The current function of the class
The current pointer of the class
The current object of the class
A value of the data member
Previous
Skip
Next
Question # 12
Every class contains _______________.
Choose an answer
Constructor
Destructor
Both a constructor and a destructor
None of the given options
Previous
Skip
Next
Question # 13
Is used for ___________.
Choose an answer
calculation
reading
assigning value to variables
None of the given options.
Previous
Skip
Next
Question # 14
If we define an identifier with the statement #define PI 3.1415926 then during the execution of the program the value of PI __________.
Choose an answer
can not be replaced
None of the given options
Remain constant
can be changed by some operation
Previous
Skip
Next
Question # 15
Class is a user defined___________.
Choose an answer
Data type
Memory referee
Value
None of the given options
Previous
Skip
Next
Question # 16
Like member functions, ______ can also access the private data members of a class.
Choose an answer
Non-member functions
Friend functions
Any function outside class
None of the given options
Previous
Skip
Next
Question # 17
*.doc is _____________ by type.
Choose an answer
Sequential File
Random Access File
Data File
Record File
Previous
Skip
Next
Question # 18
&& is -------------------- operator.
Choose an answer
An arithmetic
Logical
Relational
Unary
Previous
Skip
Next
Question # 19
Overloaded new operator function takes parameter of type size_t and returns
Choose an answer
void (nothing)
void pointer
object pointer
int pointer
Previous
Skip
Next
Question # 20
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 # 21
What will be the correct syntax to assign an array named arr of 5 elements to a pointer ptr?
Choose an answer
*ptr = arr ;
ptr = arr ;
*ptr = arr[5] ;
ptr = arr[5] ;
Previous
Skip
Next
Back