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
CS-304 Final Term Exams Preparation Virtual University MCQs With Answers
Question # 1
Which of the following is the best approach to implement generic algorithms with minimum number of coding lines?
Choose an answer
Templates
Overloading
Overriding
Friend function/class
Previous
Skip
Next
Question # 2
In order to define a class template, the first line of definition must be:
Choose an answer
template
typename <template T>
Template Class
Class <Template T>
Previous
Skip
Next
Question # 3
------------- members are somewhere between public and private members. They are used in inheritance
Choose an answer
protected
public
private
global
Previous
Skip
Next
Question # 4
Which of the following are an advantage of OOP?
Choose an answer
OOP makes it easy to re-use the code
It provides an ability to create one user defined data type by extending the other
It provides the facility of defining Abstract data types through which real world entities can be defined better
All of the given options
Previous
Skip
Next
Question # 5
Which one of the following is not an object association?
Choose an answer
Simple Assocation
Inheritance
Aggregation
Composition
Previous
Skip
Next
Question # 6
The concept of derived classes is involved in,
Choose an answer
inheritance
encapsulation
array
structure
Previous
Skip
Next
Question # 7
Public methods of base class can --------- be accessed in its derived class
Choose an answer
directly
inderectly
simultaniously
none of the given
Previous
Skip
Next
Question # 8
A template argument is preceded by the keyword ________.
Choose an answer
vector
class
template
type*
Previous
Skip
Next
Question # 9
The >= operator can be overloaded.
Choose an answer
True
False
Not Sure
Previous
Skip
Next
Question # 10
Which construct is the source for the creation of an object?
Choose an answer
Destructor of the class
New operator
Delete operator
Constructor of the class
Previous
Skip
Next
Question # 11
Which of the following is the best approach if it is required to have more than one functions having exactly same functionality and implemented on different data types?
Choose an answer
Templates
Overloading
Data hiding
Encapsulation
Previous
Skip
Next
Back