AP CSA Unit Review #2

AP CSA Unit Review #2

9th Grade

5 Qs

quiz-placeholder

Similar activities

Review of inheritance & polymorphism

Review of inheritance & polymorphism

12th Grade

6 Qs

Post Test Multilevel Pewarisan

Post Test Multilevel Pewarisan

11th Grade

6 Qs

Python L2- Quiz 6

Python L2- Quiz 6

5th - 12th Grade

8 Qs

Java Inheritance Quiz

Java Inheritance Quiz

11th Grade

10 Qs

AP CSA - Inheritance, plus one while loop.

AP CSA - Inheritance, plus one while loop.

12th Grade

10 Qs

CodeHS 4.12 Inheritance

CodeHS 4.12 Inheritance

9th - 12th Grade

7 Qs

OOP2 Understanding Inheritance in OOP

OOP2 Understanding Inheritance in OOP

11th Grade

10 Qs

AP CSA Unit Review #2

AP CSA Unit Review #2

Assessment

Quiz

Computers

9th Grade

Medium

Created by

ANTHONY MEDINA

Used 8+ times

FREE Resource

5 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

Consider the following code segment. What is the name of the superclass?

Lion

turnRight()

AnimalKingdom

SuperLion

Zoo

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Fill in the blank. Inheritance represents a/an _______ relationship.

has-a

has-many

is-a

is-many

none of the above

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Which statement below is true regarding the class declarations?

I. Drinks is a subclass of GingerAle

II. Soda is a superclass of GingerAle

III. GingerAle is a subclass of Soda

IV. GingerAle is a superclass of Drinks

I only

III only

I and II

II and IV

II and III

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the most number of times that the turnLeft( ) method would be called

0

2

3

4

infinite

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Consider the following Book and AudioBook classes. The following code segment occurs in a class other than Book or AudioBook.

Book mack = new Book( );

Which of the following code segments, written in the same class, would not run?

mack.getTitle( )

mack.getAuthor( )

mack.getNumPages( )

mack.read( )

mack.getNarrator( )