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
svlad2 [7]
3 years ago
11

Create an interface called Runner. The interface has an abstract method called run() that displays a message describing the mean

ing of run to the class. Create classes called Machine, Athlete, and PoliticalCandidate that all implement Runner.
The run() should print the following in each class:
Machine - When a machine is running, it is operating.
Athlete - An athlete might run in a race, or in a game like soccer.
PoliticalCandidate - A political candidate runs for office.
----------------------------------------------------------------------------------------------------
public class Athlete implements Runner
{
public void run()
{
// write your code here
}
}
--------------------------------------------------------------------------------------
public class DemoRunners
{
public static void main(String[] args)
{
Machine runner1 = new Machine();
Athlete runner2 = new Athlete();
PoliticalCandidate runner3 = new PoliticalCandidate();
runner1.run();
runner2.run();
runner3.run();
}
}
------------------------------------------------------------------------------------------
public class Machine implements Runner
{
public void run()
{
// write your code here
}
}
----------------------------------------------------------------------------------------------------
public class PoliticalCandidate implements Runner
{
public void run()
{
// write your code here
}
}
----------------------------------------------------------------------------------------------------
public interface Runner
{
// write your code here
}
----------------------------------------------------------------------------------------------------

Computers and Technology
1 answer:
4vir4ik [10]3 years ago
5 0

Answer:

Please find the code and its output in the attached file.

Explanation:

In the above-given code, an interface "Runner" is defined, inside the interface, an abstract method run is declared.

In the next step, three class "Athlete, Machine, and PoliticalCandidate" s defined that implements the run method, and use the print message that holds a given value as a message.

In the next step, a class "DemoRunners" is defined, and inside the main method, the three-class object is declared, which calls the run method.

 

You might be interested in
New trends, tools, and languages emerge in the field of web technology every day. Discuss the advantages of these trends, tools,
ikadub [295]

Answer:

Explanation:However, with the emergence of several new web development technologies, tools, frameworks, and languages in the last few years, it has now become quite .

7 0
3 years ago
Who is the person responsible for creating the original website content?
Romashka [77]

Answer: D) Content creator

Explanation:

  • Content creator are responsible for creating the original content of the website. They contribute writing the blog posts about various topics and promote the content with the help of digital and social media.
  • Content creator are basically responsible for writing blog post on the industry based topics, graphic design and video editing.

Content editor uses data and evaluation from the users for analysis. It basically includes design and development to enhanced the material on the website.

Static and dynamic information are related to computer terminologies.

Therefore, (D) option is correct.

8 0
3 years ago
To share a server folder, access the ____ tab in the folder properties dialog box and click the share button (or from the window
anygoal [31]
Oh lord I have no idea :/ I suck at this yeah idk
5 0
3 years ago
What is a small handheld computer that performs simple tasks such as taking notes, scheduling appointments, and maintaining an a
antiseptic1488 [7]

is a small handheld computer that performs simple tasks such as taking notes, scheduling appointments, and maintaining an address book and a calendar PDA.

<h3><u>Explanation:</u></h3>

Personal Digital Assistant is the full form for PDA. PDAs are the computers in smaller size. They perform all works that are performed by a computer. They help you in viewing all the documents that you need, scheduling all your works,etc. They act as a mini sized computer that you can take where ever you go.

Using PDAs you can easily schedule any tasks, take notes, maintain all your contacts in address books,etc. Even though the markets of PDAs is not having higher demands because of the existence of i phones and other devices that are identical to i phones, there are still some usages and demands for PDAs. These are used in industries and businesses.

3 0
3 years ago
Pick a web browser (a leading one or perhaps a lesser-known one that you use) and examine the Privacy and Security features and
Veseljchak [2.6K]

Solution :

<u>Chrome web browser</u>

The Chrome web browser uses a range of privacy and security settings for its customers. They include several security indicators as well as malware protection. Chrome uses the sandboxing technology, which prevents the harmful viruses and Trojans from reaching the computers.

Chrome provides a safe browsing by giving us an alert whenever we try to browse some harmful web sites.  It also warns you if we use a username and password combination which has been compromised in any data leak.

Chrome also serves to protect the individuals :

It provides a features of Ad blocking.

When we want to browse safely without being recognized or without storing any credentials, Chrome provides an Incognito mode.

Many businesses can be done on the internet using Chrome platform that is safe and authenticate to gather and collect data and information.

3 0
3 years ago
Other questions:
  • Jason works as an accountant in a department store. He needs to keep a daily record of all the invoices issued by the store. Whi
    5·2 answers
  • How is the Task Manager helpful in displaying which resources your computer is using and how fast?
    5·2 answers
  • 2 negative impact of excessive use of computer even in solving mathematical problem.
    11·1 answer
  • Can Someone give me a 5 paragraph essay about all of the uses in Microsoft Word.
    9·1 answer
  • One megabyte is approximately __________.
    7·2 answers
  • What is the name for a partition that has been formatted and assigned a drive letter?
    8·1 answer
  • What percentage of people with internet access use emojis?
    11·1 answer
  • Write a program that produces an expense report for a trip to Lagos, Nigeria. Use the Internet to research the cost to travel to
    13·1 answer
  • Which of the following parameters is optional sample(a,b,c,d=7
    9·1 answer
  • Where is the flash drive listed in a windows 7 save as dialog box?
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!