answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Alexeev081 [22]
1 year ago
14

Insert the missing code in the following code fragment. This fragment is intended to call the Vehicle class's method. public cla

ss Vehicle { . . . public void setVehicleClass(double numberAxles) { . . . } } public class Motorcycle extends Vehicle { . . . public Motorcycle() { _______________; } }
Computers and Technology
1 answer:
gayaneshka [121]1 year ago
3 0

Answer:

The answer is D.

Explanation:

The question is incomplete, here is the full question;

Insert the missing code in the following code fragment. This fragment is intended to call the Vehicle class's method.

public class Vehicle

{

. . .

public void setVehicleClass(double numberAxles)

{

. . .

}

}

public class Motorcycle extends Vehicle

{

. . .

public Motorcycle()

{

_______________;

}

}

a) Motorcyle.setVehicleClass(2.0);

b) Vehicle.setVehicleClass(2.0);

c) this.setVehicleClass(2.0);

d) setVehicleClass(2.0);

According to the information and the code snippet given in the question, the correct answer to fill in the blank should be D,  setVehicleClass(2.0); because it is in the Motorcycle class which "extends" vehicle meaning that it's a subclass.

I hope this answer helps.

You might be interested in
It has been said that the quality of our relationships depends in large part on the quality of our
timurjin [86]

Answer:

people

Explanation:

6 0
2 years ago
Nancy would like to configure an automatic response for all emails received while she is out of the office tomorrow, during busi
Stella [2.4K]

she can appoints someone she trust to act on her behalf

4 0
2 years ago
Read 2 more answers
What would make this comparison statement False? Complete with the appropriate relational operator. "G" _____= "G"
My name is Ann [436]

Equality and Relational Operators

For the statement to return false, you can simply use the "not equal to" equality operation. The full symbol of this operation is '!=', disregarding the quotes.

<u>Examples:</u>

  • [1 != 1]  would produce FALSE. Translation: 1 <u>does not equal</u> 1?
  • [1 == 1]  would produce TRUE. Translation: 1 <u>does</u> 1?
  • ["G" != "G]  would produce <u>FALSE</u>. Translation: "G" <u>does not equal</u> "G"?

CONCLUSION: Use "!=".

8 0
2 years ago
5.William travels a lot on business purpose. He needs to regularly communicate with his business partner. He also needs to send
FromTheMoon [43]

Microsoft Online is free to use. It includes Microsoft Excel, Word, One - Note and PowerPoint.  Microsoft Outlook (email app) is free as well, although it is a seperate download.

Another way to go is via Google docs, The Google drive is rather large and safe to store reports, docs, images, etc.

Both Microsoft online and Google Docs are accessible to use on virtually any device as in: PCs, Laptops, Tablets, Androids and Iphones.


4 0
1 year ago
Fiona is drawing polygons on a computer. She wants to map a regular 9-sided polygon back onto itself using a reflection. Which s
Rus_ich [418]
The answer is "<span>B) any perpendicular bisector of one of the sides".
</span>
We can define a line of reflection as the line in which a shape is reflected, or we can say that it is the mirror in which the shape is reflected. The line of reflection is the perpendicular bisector of any pair of corresponding points. If you want to join sets of corresponding points on the object and image, then the line of reflection will slice the lines framed down the middle.
4 0
1 year ago
Read 2 more answers
Other questions:
  • Which of the following is not a benefit of active listening?
    8·1 answer
  • A simplified main program used to test functions is called
    10·1 answer
  • All the employees of Delta Corporation are unable to access the files stored in the server. What do you think is the reason behi
    14·1 answer
  • You are given an array x of string elements along with an int variable n that contains the number of elements in the array. You
    11·1 answer
  • In mathematics, the notation n! represents the factorial of the nonnegative integer n. The factorial of n is the product of all
    7·1 answer
  • Information gathered from observing a plant grow 3 cm over a two-week period results in _______.a. inferences. b. variables. c.
    11·1 answer
  • Your company wants to conduct an exploratory study to gain new insights into some product changes you are considering. Which typ
    15·1 answer
  • We Deliver trains its truck loaders how to set the packages in the delivery vehicles, so that when delivery drivers are pulling
    15·1 answer
  • Read the four detective reports and the combined affidavit and warrant for the M57 Patents case. Write a one- to two-page paper
    5·1 answer
  • Choose the correct function to convert the user’s response to the number 3.5. &gt;&gt;&gt; answer = input("How much does the sam
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!