0 ratings0% found this document useful (0 votes) 191 views7 pagesObject Oriented Programming Prelim Quiz 2
Object Oriented Programming Prelim Quiz 2 Ama
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here.
Available Formats
Download as PDF or read online on Scribd
419323, 12:17 AM Prelim Quiz 2: Attempt review
Started on Thursday, 26 January 2023, 5:25 PM
State Finished
Completed on Thursday, 26 January 2023, 5:32 PM
Time taken 6 mins 45 secs
Marks 20.00/20.00
Grade 100.00 out of 100.00,
ueston 1
‘The class whose properties and functionalities are use (inherited) by another class is known 25,
Select one:
a Parent Class
b. Child Class
Sub Chass
4d. Band
overon 2
‘One ofthe OOP feature that allows us te perform a single action in diferent ways
Select one
8. Abstraction
b. Encapsulation
© Polymorphism
1d. Inhertance
ueston 3
‘The capabiliy of a method to do different things based on the abject that its acting Upon. In other words, i allows you define one interface
and have mutate implementations.
Select one
2. Polymorphism
b. Abstraction
© Encapsulation
1d. Inhertance
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032419323, 12:17 AM Prelim Quiz 2: Attempt review
ueston
‘Sub classi invoked when we create the object of subelass it by default invokes the default constructor of superclass.
Select one:
8. Super Class
b. Super Keyword
© Constructor
4. Imbertance
werton 5
Ithas the static Keyword asa prefix in its declaration. ts definition occurs only inside a class and outside any function.
Select one
2. Class variables
b. Instance variables
& Variable Types
4
Local variables
ueston 6
‘The super keyword refers tothe immediately above of the calling class inthe hierarchy.
Select one
8 Super Class¥
b. Constructor
Super Keyword
4. Inhertance
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032419323, 12:17 AM Prelim Quiz 2: Attempt review
ueston 7
This is the most restrictive and mes
accessed within the same cass
commonly used access moifer. Ifyou use the this mauler with an attribute or method t can only be
Select one
a. Private
b. No Modifier
Protected
d. Public
‘These variables are inside a class however outside any method. They come into existence when the class instantates
Select one
2 Class variables
b, Local variables
Variable Types
Instance variables
weston 9
‘The superclass constructor can be called explicitly using the 2
Select one
2. Constructor
b. Super Cass
Inheritance
4. Super Keyword
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032
a7419323, 12:17 AM Prelim Quiz 2: Attempt review
‘quesvon 10
‘The same method in child cass which is already present inthe parent class.
Select one
2 Object Overrising
b, Method Overiding¥
& Method Overloading
4. Object Overloading
weston 11
‘These are variables which have declarations inside methods, constructors or blocks.
Select one
Class variables
Variable Types
Local variables
Instance variables
ueston 12
This is the least restrictive access mosifer. Methods and attributes that use the public modifier can be accessed within your current cass and by
all other classes
Select one
2. No Modifier
b. Publicey”
Private
Protected
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032419323, 12:17 AM Prelim Quiz 2: Attempt review
quesvon 13
‘The class that extends the features of another las is known as
Select one:
a Banacy
b. Parent Class
Sub Chass
4. Child Cass
werton 14
Itis a blueprint for objects to follow a specific schema defined inthe class.
Select one
Method
Object
Behavior
Class¥
uesvon 15
‘The process by which one cass acquires the properties (data members) and functionaites(methods) of another class.
Select one
8 Encapsulation
b. Abstraction
& Inbertance¥
Polymorphism
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032419323, 12:17 AM Prelim Quiz 2: Attempt review
uesvon 16
‘The following are the advantages of Inheritance except
Select one:
18. Avoids duplicity and data redundancy
b. Allows you to define one interface
&Reusabilty of code
1d. One superclass can be used for the numberof subclasses ina hierarchy
uerton 17
Select one
2. No Modifier
b. Protected
Public
4. Private
venton 18
[Attributes and methods with the access modifer protected can be accessed within your clas, by all lasses within the same package, and by all
subelasses within the same or other packages,
Select one
8. No Modifier
b. Protected
Private
4. Public
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032419323, 12:17 AM Prelim Quiz 2: Attempt review
quesvon 19
Use to define the visibility of classes, methods, and attributes.
Select one
Access Modifier”
b. Private
Public
Protected
‘querton 20
It isthe most fundamental entity in ava or any other Object Oriented Language.
Select one
8. Behavior
b. Object
Clase
d. Method
hitps:vimesral amaesontine,com/2223Amodiquzitview php ?allempt=4S2068emid=5032
W
You might also like
STD-12 Computer CH-5,6,7,8,9,10 Textual MCQ'S
STD-12 Computer CH-5,6,7,8,9,10 Textual MCQ'S
10 pages