1answer.
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
Aloiza [94]
3 years ago
15

java Consider a class MotorBoat that represents motorboats. A motorboat has attributes for: The capacity of the fuel tank The am

ount of fuel in the tank The maximum speed of the boat The current speed of the boat The efficiency of the boat's motor The distance traveled The class has methods to: Change the speed of the boat Operate the boat for an amount of time at the current speed
Computers and Technology
1 answer:
zubka84 [21]3 years ago
5 0

Explanation:

Below is the java code for the class MotorBoat  : -

public class MotorBoat {

   private int tankCapacity;

   private int fuelAmount;

   private double maxBoatSpeed;

   private double currentBoatSpeed;

   private double efficacy;

   private double distanceTravelled;

   

   public void changeSpeed(double speed){

       currentBoatSpeed = speed;

   }

   public double operateBoat(double time){

       distanceTravelled = currentBoatSpeed * time;

       return distanceTravelled;

   }

}

You might be interested in
What type of input and output devices would be ideal for a college student completing his or her coursework?
Xelga [282]
If your looking for devices that help a college student get answers or help Air Math is great, along with Homework Helper. Sorry if this is not what your asking for, but it helps!
4 0
2 years ago
How is ( a || b ) && c || ( a || b ) && ( ! c ) equal to ( a || b ) without simplification?
kogti [31]

Answer: You can see the truth table in the image.

Explanation:We can do this question by using truth table.

As we can see in the truth table that there is no effect on the output of the expression by c if a and b both are false then the output is false and if any of them is True or both of them are True then the result is True.

8 0
3 years ago
Application software sold with new device is called ________.
Vinil7 [7]

The name which is given to an application software which is sold with new device is called:

  • Killer application

<h3>What is a Killer Application?</h3>

This refers to the software which is necessary to the functioning of a core value of another technology.

With this in mind, we can see that because these application software are sold with new devices and are made to complement the core values of a tech, then they are referred to a killer app.

Read more about application software here:
brainly.com/question/1538272

4 0
3 years ago
Your mobile device has gone over its subscribed data limit the past two months. During this time, you have noticed that the devi
Zolol [24]

Answer:D. The device needs an operating system update

Explanation:Operating systems are different programs mainly manufactured by software companies like Microsof,Apple etc, after initially installation are loaded into the computer by a boot program, operating systems manages all of the other application programs in a computer, it requires constant upgrade in order to be able to effectively carry out its activities. Application programs uses the operating system by making requests for services through a defined application program interface (API). Examples include Windows 7, Windows 8, Windows 10, Blackberry OS, Operating system Linux etc.

6 0
3 years ago
You need to write a menu driven program. The program allows a user to enter five numbers and then asks the user to select a choi
Jobisdone [24]

Answer:

In Python:

nums = []

for i in range(5):

   num = int(input("Num: "))

   nums.append(num)

print("1 - Smallest")

print("2 - Largest")

print("3 - Sum")

print("4 - Average")

menu = int(input("Select menu: "))

if menu == 1:

   print("Smallest: ",min(nums))

elif menu == 2:

   print("Largest: ",max(nums))

elif menu == 3:

   isum = 0

   for i in range(5):

       isum+=nums[i]

   print("Sum: ",isum)

elif menu == 4:

   isum = 0

   for i in range(5):

       isum+=nums[i]

   print("Average: ",isum/5)

else:

   print("Invalid Menu Selected")

Explanation:

This program uses a list to get inputs for the 5 numbers

Here, the list is initialized

nums = []

This iterates from 1 to 5

for i in range(5):

This gets input for the 5 numbers

   num = int(input("Num: "))

This appends each number to the list

   nums.append(num)

The next 4 lines represents the menu

<em>print("1 - Smallest")</em>

<em>print("2 - Largest")</em>

<em>print("3 - Sum")</em>

<em>print("4 - Average")</em>

This prompts the user for menu

menu = int(input("Select menu: "))

If menu is 1, print the smallest

<em>if menu == 1:</em>

<em>    print("Smallest: ",min(nums))</em>

If menu is 2, print the largest

<em>elif menu == 2:</em>

<em>    print("Largest: ",max(nums))</em>

If menu is 3, calculate and print the sum of all inputs

<em>elif menu == 3:</em>

<em>    isum = 0</em>

<em>    for i in range(5):</em>

<em>        isum+=nums[i]</em>

<em>    print("Sum: ",isum)</em>

If menu is 4, calculate and print the average of all inputs

<em>elif menu == 4:</em>

<em>    isum = 0</em>

<em>    for i in range(5):</em>

<em>        isum+=nums[i]</em>

<em>    print("Average: ",isum/5)</em>

If menu is not 1 to 4, then print invalid menu

<em>else:</em>

<em>    print("Invalid Menu Selected")</em>

3 0
3 years ago
Other questions:
  • A single point of failure is a piece of hardware or application that is key to ________________________.
    8·1 answer
  • How you think the new values of your generation will affect economic decisions?
    11·1 answer
  • Clep allows students to do all of thw following except which?
    9·2 answers
  • Write a c++ function, largestnum, that takes as parameters a double array and its size and returns the index of the last occurre
    14·1 answer
  • Which of the following solutions enables simultaneous digital transmission of voice, video, data, and other network services ove
    7·1 answer
  • Which of these is an example of open-source software?
    13·1 answer
  • What properties make it suitable to be used for supportive frames
    15·1 answer
  • What is the largest positive number one can represent in an eight-bit 2’s complement code? Write your result in binary and decim
    7·1 answer
  • When is 1600 plus 25 and 1700 minus 35 the same thing?​
    10·1 answer
  • Spam is _____.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!