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 normal source of cin object is
Choose an answer
File
Disk
Keyboard
RAM
Previous
Skip
Next
Question # 2
Is used for ___________.
Choose an answer
calculation
reading
assigning value to variables
None of the given options.
Previous
Skip
Next
Question # 3
What is the sequence of event(s) when allocating memory using new operator?
Choose an answer
Only block of memory is allocated for objects
Only constructor is called for objects
Memory is allocated first before calling constructor
Constructor is called first before allocating memory
Previous
Skip
Next
Question # 4
Memory allocated at run time is a system resource and it is the responsibility of _____ to de-allocate the memory.
Choose an answer
System
Programmer
User of program
None of given options
Previous
Skip
Next
Question # 5
A Pointer is a special variable that contain.
Choose an answer
Data values
Memory Address
Both data and values
None of the given option
Previous
Skip
Next
Question # 6
Assignment operator is -------------------------associative.
Choose an answer
right
left
binary
unary
Previous
Skip
Next
Question # 7
How many bytes will the pointer intPtr of type int move in the following statement? intPtr += 3 ;
Choose an answer
3 bytes
6 bytes
12 bytes
24 bytes
Previous
Skip
Next
Question # 8
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 # 9
UNIX has been developed in ________ language
Choose an answer
JAVA
B
C
FORTRAN
Previous
Skip
Next
Question # 10
The return type of the operator function for << operator is __________.
Choose an answer
class for which we overload operator
reference of ostream class (ostream&)
reference of istream class (istream&)
void
Previous
Skip
Next
Question # 11
The return type of a function that do not return any value must be ________.
Choose an answer
float
int
void
double
Previous
Skip
Next
Question # 12
Pointer is a variable which store
Choose an answer
Data
Memory Address
Data Type
Values
Previous
Skip
Next
Question # 13
*.doc is _____________ by type.
Choose an answer
Sequential File
Random Access File
Data File
Record File
Previous
Skip
Next
Question # 14
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 # 15
If text is a pointer of class String then what is meant by the following statement? text = new String [5];
Choose an answer
Creates an array of 5 string objects statically
creates an array of 5 string objects dynamically
Creates an array of pointers to string
Creates a string Object
Previous
Skip
Next
Question # 16
To access the data members of structure _______ is used.
Choose an answer
dot operator
* operator
U operator
None of given
Previous
Skip
Next
Question # 17
When an object of a class is defined inside an other class then
Choose an answer
Constructor of enclosing class will be called first
Constructor of inner object will be called first
Constructor and Destructor will be called simultaneously
None of the given options
Previous
Skip
Next
Question # 18
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 # 19
new and delete are _____ whereas malloc and free are _____.
Choose an answer
Functions, operators
Classes, operators
Operators, functions
Operators, classes
Previous
Skip
Next
Question # 20
Which one of the following is the declaration of overloaded pre-increment operator implemented as member function?
Choose an answer
Class-name operator +()
Class-name operator +(int)
Class-name operator ++() ;
Class-name operator ++(int) ;
Previous
Skip
Next
Question # 21
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
Back