Online Exam Preparation

MCQs Library

Browse subject-wise multiple choice questions, review answers quickly, and start a test from the same section.

Course Codes

Select a course to load its MCQs.

Selected: CS304 192 MCQs
CS101 533 CS201 225 CS301 232 CS302 174 CS304 192 CS401 224 CS402 258 CS403 228 CS408 113 CS411 121 CS502 249 CS504 268 CS601 679 CS604 381 CS605 261 CS607 184 CS609 230 CS610 300 CS614 100 CS703 65

Questions

Showing page 4 of 10

Code Question Option A Option B Option C Option D Answer
CS304
Data Members Are The Attributes Of Objects
True
False
Na
Na
A
CS304
Default Constructor Is Such Constructor Which Either Has No ---------Or If It Has Some Parameters These Have -------- Values
Parameter Temporary
Null Parameter
Parameter Default
Non Of The Given
C
CS304
Destructor Can Be Overloaded
True
False
Na
Na
B
CS304
Each Try Block Can Have No. Of Catch Blocks
1
2
3
As Many As Necessary
D
CS304
Friend Class And Friend Function Can Be Used As An Alternate To Each Other
True
False
Na
Na
B
CS304
Friend Functions Are __________ Functions Of A Class
None Of Given
Object Member
Non-Member
Data Member
C
CS304
Function Templates Should Be Used Where Code And Behavior Must Be Identical
True
False
Na
Na
A
CS304
Given The Following Class Class Base { Int Age=33; } How You Can Improve Above Class With Respect To Accessing The Field Age?
Define The Variable Age As Private
Define The Variable Age As Protected
Define The Variable Age As Private And Create A Get Method That Returns It And A Set Method That Updates It
Define The Variable Age As Protected And Create A Set Method That Returns It And A Get Method That Updates It
C
CS304
Graphical Representation Of The Classes And Objects Is Called Object Model It Shows - ------
Class Name Only
Class Name And Attributes
Relationships Of The Objects And Classes
All Of The Given
D
CS304
Identify The Correct Way Of Declaring An Object Of User Defined Template Class A For Char Type Members?
A< Char > Obj;
<Char>A Obj;
A Obj<Char>;
Obj <Char> A;
C
CS304
Identify Which Of The Following Overloaded Operator Function‘S Declaration Is Appropriate For The Given Call? Rational_Number_1 + 2.325 Where Rational_Number_1 Is An Object Of User Defined Class Rational_Number
Rational_Number Operator+( Rational_Number & Obj);
Rational_Number Operator+(Double& Obj);
Rational_Number Operator+(Rational_Number &Obj Double& Num);
Operator+(Double& Obj);
B
CS304
If A Class A Inherits From Class B Then Class A Is Called
Child Class
Derived Class
Parent Class
Child And Derived Class
B
CS304
If A Class D Has Been Derived Using Protected Inheritance From Class B (If B Is A Protected Base And D Is Derived Class) Then Public And Protected Members Of B -------- Accessed By Member Functions And Friends Of Class D And Classes Derived From D
Can Be
Cannot Be
Does Restirct To Be
Not Given
A
CS304
If A Class Involves Dynamic Memory Allocation Thena
Default Copy Constructor Shallow Copy Is Implement
User Defined Copy Constructor Shallow Copy Is Impl
Default Copy Constructor Deep Copy Is Implemented
User Defined Copy Constructor Deep Copy Is Implem
A
CS304
If Myclass Has A Destructor What Is The Destructor Named?
Myclass
~Myclass
My~Class
Myclass~
B
CS304
If Only One Behaviour Of A Derived Class Is Incompatible With Base Class Then It Is
Generalization
Specialization
Extension
Inheritance
B
CS304
If Some Of Objects Exhibit Identical Characteristics Then They Belong To
Different Classes
Multiple Classes
Same Class
None Of The Given
C
CS304
If We Are Create Array Of Objects Through New Operator Then
We Can Call Overloaded Constructor Through New
We Can‘T Call Overloaded Constructor Through New
We Can Call Default Constructor Through New
None Of The Given
A
CS304
In __________ A Base Class Can Be Replaced By Its Derived Class
Sub-Typing
Super-Typing
Multiple-Typing
Restricted-Typing
A
CS304
In A De-Queue (Chose The Best Option)
Data Can Be Quickly Inserted Or Deleted At Any Arbitrary Location
Data Can Be Inserted Or Deleted At Any Arbitrary Location But The Process Is Relatively Slow
Data Can Not Be Quickly Inserted Or Deleted At Either End
Data Can Be Inserted Or Deleted At Either End But The Process Is Relatively Slow
D