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
Iteru [2.4K]
3 years ago
14

For this question you must write a java class called Rectangle and a client class called RectangleClient. The partial Rectangle

class is given below. (For this assignment, you will have to submit 2 .java files: one for Rectangle class and the other one for RectangleClient class.) // A Rectangle stores an (x, y) coordinate of its top/left corner, its width and height. public class Rectangle { private int x; private int y; private int width; private int height; // constructs a new Rectangle with the given inX, inY and inSideLength public Rectangle(int inX, int inY, int inWidth, int inHeight) // returns the fields' values public int getX() public int getY() public int getWidth() public int getHeight() public int getArea() public bool IsSquare() // returns a string such as "Rectangle located at (1,2) with dimensions 3x4 and area 49.", where 3 is width, 4 is height and 12 is the area. public String toString() ... }
Computers and Technology
1 answer:
polet [3.4K]3 years ago
8 0

Answer:

Java.

Explanation:

public class Rectangle {

   private int x;

   private int y;

   private int width;

   private int height;

   ///////////////////////////////////////////////////////////

   public Rectangle(int inX, inY, inWidth, inHeight) {

       x = inX;

       y = inY;

       width = inWidth;

       height = inHeight;

   }

   ///////////////////////////////////////////////////////////

   public int getX() {

       return x;

   }

   public int getY() {

       return y;

   }

   

   public int getWidth() {

       return width;

   }

   public int getHeight() {

       return height;

   }

   ///////////////////////////////////////////////////////////

   public int getArea() {

       return width * height;

   }

   public bool isSquare() {

       if (width == height) {

           return true;

       }

       else

           return false;

   }

   ///////////////////////////////////////////////////////////

   public String toString() {

       return "Rectangle located at (" + x + "," + y + ")" + "with dimensions " + width + "x" + height + "and " + getArea() + "is the area.";

   }

}

You might be interested in
Which term refers to the technical structure of the software, how users interact with the software, and how the software is phys
mars1129 [50]
The Answer is <span> Architecture</span>
7 0
3 years ago
Output from the print statement is usually written to the ______ in the form of ________
alexdok [17]

Answer:

Hope this helps :)

Explanation:

To the *processor* in the form of *binary* (or binary language)

8 0
4 years ago
What are the computer/electronic needs<br> that drive our economy today?
Nesterboy [21]

Power plants, water, dams, and electricity.

8 0
3 years ago
To add artwork to a slide, the slide must contain a placeholder. <br> a. True <br> b. False
valina [46]
The answer is True.  To add artwork to a slide, the slide must contain a placeholder. <span>Once </span>artwork<span> is inserted into a </span>placeholder<span>, it can be moved around the </span>slide<span>.</span>
5 0
4 years ago
Please help!!!!!!! 50 POINTS!!!!
mrs_skeptik [129]

Answer:

A,D,C,B are the correct answers

Explanation:

Hope this helps:)

3 0
3 years ago
Other questions:
  • Required
    12·1 answer
  • Does the game best fiend need wifi to play on the app?
    8·2 answers
  • What type of link is used to call this file?
    8·1 answer
  • How do issues of equity, teacher education and budgeting impact technology in schools?
    7·2 answers
  • Which of the following lists contains the five essential elements of a computer? Group of answer choices: 1. inputs, returns, pr
    11·1 answer
  • Henry has created a software that manages a database of all his music.he wishes to run the software on another computer system t
    5·1 answer
  • Give one example of where augmented reality is used​
    11·2 answers
  • 0 % 3? Is it 0 or undefined? (% is mod)
    9·1 answer
  • Analyze the sentence below . choose your answer on the box below write your answer in your quiz notebook
    5·1 answer
  • How do you answer someone's question when they have asked?
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!