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
Marrrta [24]
3 years ago
8

The ABC Carpet Company has asked you to write an application that calculates the price of carpeting for rectangular rooms. To ca

lculate the price, you multiply the area of the floor (width times length) by the price per square foot of carpet. For example, the area of floor that is 12 feet long and 10 feet wideis 120 square feet. To cover that floor with carpet that costs $8per square footwould cost $960. (12x10x8= 960)
Computers and Technology
1 answer:
Annette [7]3 years ago
8 0

Answer:

class RoomDimension

{

double length;

double width;

public RoomDimension(double len, double w)

{

length = len;

width = w;

}

public double getLength()

{

return length;

}

public double getWidth()

{

return width;

}

public double getArea()

{

return length * width;

}

public String toString()

{

String output;

output = "Room dimensions:\nLength: " + length + "\nWidth: " + width + "\nArea: " + getArea();

return output;

}

}

And the code for RoomCarpet.java:

class RoomCarpet //extends RoomDimension

{

RoomDimension size;

double carpetCost;

public RoomCarpet(RoomDimension dim, double cost)

{

size = new RoomDimension(dim.getLength(), dim.getWidth());

carpetCost = cost;

}

public double getTotalCost()

{

return carpetCost;

}

public String toString()

{

String output = size + "\nCarpet cost: $" + carpetCost * size.getArea();

return output;

}

}

You might be interested in
How is your day going?Technology affects the learning experience of students by helping them
Alex_Xolod [135]

Answer:

is this technology or

Explanation:

computer

5 0
3 years ago
Read 2 more answers
what would you have to do to delete a document from your computer so that it could not possibly be read by anyone else?
Ket [755]

Answer:

Remove the doc using the trash button on it, bit if that doesn't work, just backspace the whole thing (an easier way to backspace it is to highlight everything you typed and hit backspace once).

7 0
2 years ago
Which generation of programming languages provides programmers with a visual environment to code programs?A. first generationB.
Mila [183]

the answer is c third generation

3 0
3 years ago
Decision-making problems that can be stated as a collection of desired goals are known as what type of problem? A goal programmi
Vera_Pavlovna [14]

Answer:

True. A goal programming problem

Explanation:

Goal programming is an optimisation technique to solve problems with multiplicity of objectives, which are generally in commensurable and they often conflict each other in a decision making horizon.In a certain programming environment, optimisation of a set of objectives is involved there in the decision situation. Here, instead of optimising them directly, achievement of the assigned target values called aspiration levels of them is considered. In goal programming method, the unwanted deviations (under and / or over) from the aspired levels are minimised in the goal achievement function (objective function) to reach a satisfactory solution in a crisp decision environment

4 0
3 years ago
Which of the following is a true statement about cloud computing?
Veseljchak [2.6K]

Answer:

There are additional security risks associated with using cloud computing over local data storage.                    

Explanation:

Cloud computing: The term "cloud computing" is described as a process through which an individual tends to access and store various programs and data over the internet rather than his or her computers' "hard drive". However, the term "cloud" here refers to a specific metaphor associated with the internet.

Types:

1. Software-as-a-service or SaaS.

2. Platform-as-a-service or PaaS.

3. Infrastructure-as-a-service or IaaS.

In the question above, the very first option is correct as all other options mentioned over here are incorrect because they aren't related to cloud computing.

3 0
3 years ago
Other questions:
  • How can you best utilize CSS for Web Development?
    6·1 answer
  • Up to 10 people is a good guideline for the size of your study group.
    15·1 answer
  • What did Edison's device to view motion pictures inspire the Lumiere brothers to invent?
    14·1 answer
  • Which of the following scanning technique attackers use to bypass firewall rules, logging mechanism, and hide themselves as usua
    11·1 answer
  • Why might it be a good idea to choose a bus topology?
    6·2 answers
  • Technician A says that Teflon sealing rings require special tools for proper installation. Technician B says that warming a Tefl
    5·1 answer
  • HELP ASAP!!!
    7·1 answer
  • Which is the correct expansion of the term Internet?
    15·2 answers
  • Which font is most suitable for an academic article on a website? Which is most suitable for casual information?
    5·2 answers
  • 5. A Disk defragmenter tool does what to a computer HDD?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!