
CS 122 - Final Examination
Authored by Christine Pitos
Computers
University
Used 7+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
16 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A way to discover which of the two classes is the base class and which is the subclass is to _______.
look at the class size
try saying the two class names together
use polymorphism
Both a and b are correct
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Employing inheritance reduces errors because ______.
the new classes have access to fewer data fields
the new classes have access to fewer methods
you can copy methods that you already created
many of the methods you need have already been used and tested
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A base class can also be called a ______.
child class
subclass
derived class
superclass
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following choices is the best example of a parent class/child class relationship?
Rose/Flower
Present/Gift
Dog/Poodle
Sparrow/Bird
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The Java keyword that creates inheritance is _____.
static
enlarge
extends
inherits
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A class named Building has a public, nonstatic method named getFloors(). If School is a child class of Building, and modelHigh is an object of type School, which of the following statements is valid?
Building.getFloors();
School.getFloors();
modelHigh.getFloors();
All of the previous statements are valid.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements is true?
A child class inherits from a parent class.
A parent class inherits from a child class.
Both of the preceding statements are true.
Neither a nor b is true.
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
20 questions
Artificial Intelligence CT-1
Quiz
•
University
20 questions
Micro Arch - CPUs & Fetch-Execute
Quiz
•
University
14 questions
TECHNOLOGY
Quiz
•
3rd Grade - Professio...
20 questions
Python Recap
Quiz
•
7th Grade - University
12 questions
Python Quiz 1.4
Quiz
•
University
13 questions
Processing Quiz
Quiz
•
University
20 questions
Kiến thức về Thuật toán và Chương trình
Quiz
•
8th Grade - University
17 questions
STIN (EM24) - Tecnologías 4.0 (T13)
Quiz
•
University - Professi...
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade