Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 110.05 pts Which Java keyword can be used to access the super class version of an overridden method from within the sub class? override

Question 110.05 pts

Which Java keyword can be used to access the super class version of an overridden method from within the sub class?

override
super
new
this
extends

Flag this Question

Question 120.05 pts

Given the following code (assume that the statements compile with NO syntax errors):

Red hot = new Red(); Green top = hot; Orange ocean = new Blue(); hot = ocean;

What is the static type of 'top'?

Green
hot
Red
top

Flag this Question

Question 130.05 pts

Given the following code (assume that the statements compile with NO syntax errors):

Red hot = new Red(); Green top = hot; Orange ocean = new Blue(); hot = ocean;

What is the dynamic type of 'ocean' after all the statements have been executed? (Tip: draw an object diagram!)

Orange
hot
Red
Blue

Flag this Question

Question 140.05 pts

Given the following code (assume that the statements compile with NO syntax errors):

Red hot = new Red(); Green top = hot; Orange ocean = new Blue(); hot = ocean;

What is the dynamic type of 'hot' after all the statements have been executed? (Tip: draw an object diagram!)

Red
ocean
Blue
Orange

Flag this Question

Question 150.05 pts

What determines which version of an overriddenmethod is executed?

the static type of the variable that acts as the 'qualifier' in the method call
the dynamic type of the variable that acts as the 'qualifier' in the method call
the data types of the arguments of the method call
the name of the class where the method call is located
the name of the method

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Guide To Client Server Databases

Authors: Joe Salemi

2nd Edition

1562763105, 978-1562763107

More Books

Students also viewed these Databases questions