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
VashaNatasha [74]
2 years ago
8

Design and implement your own simple class to represent any household item of your choice (toaster, fan, hair dryer, piano ...)

Your class should have a constructor, one additional method and at least one member variable (e.g. boolean isOn to turn the item on or off). Be sure you demonstrate your class works properly by constructing an instance of it and calling your method.
Medicine
1 answer:
jeyben [28]2 years ago
7 0

Answer:

public class Fan {

/** Main method */

public static void main(String[] args) {

 final int SLOW = 1;  // Fan speed slow

 final int MEDIUM = 2; // Fan speed medium

 final int FAST = 3;  // Fan speed fast

 // Create two Fan objects

 Fan fan1 = new Fan();

 Fan fan2 = new Fan();

 

 fan1.setSpeed(FAST);

 fan1.setRadius(10);

 fan1.setColor("yellow");

 fan1.turnOn();

 

 fan2.setSpeed(MEDIUM);

 fan2.setRadius(5);

 fan2.setColor("blue");

 fan2.turnOff();

 System.out.println(fan1.toString());

 System.out.println(fan2.toString());

}

}

You might be interested in
Infants born to mothers with a prepregnancy BMI of 25 or higher are ______ to experience health problems compared to infants bor
harkovskaia [24]
They are more likely to experience health problems
3 0
2 years ago
Scientists developed a vaccine to protect humans from the h1n1 virus. what is the name of this vaccine?
fgiga [73]

Answer:

The vaccine that protect humans from the h1n1 virus is called Panvax vaccine or swine flu vaccines.

Explanation:They are inactivated H1N1 virus vaccines used for immunization of individuals 6 months of age and older against influenza disease caused by H1N1 2009 virus.

3 0
2 years ago
Which of the following is a type of anxiety disorder characterized by persistent and unwanted obsessions or compulsions that res
Mice21 [21]

Answer:

D. obsessive-compulsive disorder

Explanation:

Obsessive-compulsive disorder (OCD) is an anxiety disorder characterized by recurrent and disturbing thoughts (called obsessions) and/or repetitive, ritualized behaviors that the person feels driven to perform (called compulsions). Obsessions can also take the form of intrusive images or unwanted impulses.

3 0
3 years ago
Read 2 more answers
Free point giveaway pt.8 and brainliest to first answer
Step2247 [10]
Thanks for the points.
6 0
2 years ago
Read 2 more answers
The foundation of health-related fitness is Group of answer choices muscular endurance. a healthy body composition. muscular str
Nookie1986 [14]

The foundation of health-related fitness is muscular strength.

<h3>What is health related to fitness?</h3>

The five aspects of fitness that are directly associated to health.

  • Flexibility
  • Cardiovascular fitness
  • Muscular strength
  • Muscular endurance
  • Body composition

The definition of health-related fitness includes workout routines you follow to try to maintain and improve your physical health.

Due to the importance of heart and lung health to overall wellness, cardiorespiratory endurance is regarded as the most crucial aspect of health-related exercise.

Without a strong heart, a person simply cannot live very long or very well.

Learn more about fitness here:

brainly.com/question/20766856

#SPJ4

6 0
2 years ago
Other questions:
  • The ability to taste PTC is a dominant trait. If you cross a heterozygous taster with a non-taster, choose the correct answers b
    12·1 answer
  • If 1/2 gallon covers 1/12 of a wall, how many quarts of paint are needed to cover the entire wall?
    11·2 answers
  • Which one of the following is the best example of a student attributing success to an internal factor?A. Nita has just gotten an
    11·1 answer
  • CAN SOMEONE PLEASE MAKE A FOLLOW UP ON HOW THE PATIENT IS BASED ON THE SHORT STORY PLEASE?? NEED HELP ASAP!!! WILL MARK BRAINLIE
    12·1 answer
  • During which type of scan can you have contrast dye injected into your blood so the doctor can see your body structures more cle
    10·1 answer
  • Which of the following changes occurred in the second half of the 1900s?
    13·1 answer
  • Blood pressure is the force per unit area exerted on the wall of a blood vessel by its
    13·1 answer
  • MAY SOMEONE PLZ HELP ME ILL GIVE BRAINLEST :(((
    10·1 answer
  • The average healthy adult heart beats 70-80 beats per minute. A lower heart rate of 60 might indicate that
    9·1 answer
  • which response woudl the nurse facilitator use when a client tells the group 'i'm about to be discharged from the hosptial
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!