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
Svetach [21]
3 years ago
7

shapes polymorphism Create a set of classes derived from an abstract class Shape, which provides a common interface, for managin

g various 2D geometric shapes. In our model, each Java object will represent a shape somewhere in a Cartesian coordinate system. However, note that unlike in Mathematics, the positive y-axis grows down from the origin.All shapes have a color, of type String, and coordinates defined by integers. Individual shapes are mutable and have appropriate accessors and mutators for its unique data. See below for abstract functions declared in the base class.
Computers and Technology
1 answer:
Virty [35]3 years ago
5 0

Answer:

Explanation:

demo.java Shapes 2 Shapes Polymorphism Create a set of classes derived from an abstract class Shape, which provides a common interface, for managing various 2D geometric shapes. In our model, each Java object will represent a shape somewhere in a Cartesian coordinate system. However, note that unlike in Mathematics, the positive y-axis grows down from the origin. Shapes All shapes have the following properties: color, area, perimeter, location, and bounds. Shapes are mutable, for example any shape can be moved.

You might be interested in
A collection of a set of instrument that solve a problem is called .....​
Maru [420]

Answer:

Internet

Explanation:

A collection of a set of instrument that solve a problem is called the internet.

The Internet is an enormous networking infrastructure that uses the Internet protocol suite (TCP/IP). It connects millions of computers together globally, forming a network in which computers can communicate with each other provided that they are both connected to the Internet.

The Internet contains billions of web pages and resources created by software engineers from around the world, making it a limitless place to locate information and solve peculiar problems.

3 0
3 years ago
Read 2 more answers
Write a program that reads an unspecified number of integers, determines how many positive and negative values have been read, a
Viktor [21]

Answer:

The program to this question can be given as:

Program:

import java.util.*;

//import package for user input  

class Main     //define class

{

public static void main(String a[])  

//define main function

{

int positive_number=0,negative_number=0,count=0,num; //define variable

double total=0,avg=0;  

//creating Scanner class object.

Scanner ob = new Scanner(System.in);

System.out.println("Enter an integer, when done input 0: "); //message

num= ob.nextInt();

//taking input from user

if (num==0)  //check number equal to 0  

{  

System.out.println("No numbers are entered except 0"); //message

System.exit(1);

}

else

{

while (num!= 0)  

{    

   if (num> 0)

   {

positive_number++; // Increase positives

}

else

{

negative_number++; // Increase negatives

}

total=total+num; // Accumulate total

count++;    // Increase the count

num=ob.nextInt();

}

// Calculate the average

avg=total/count;

// Display values

System.out.println("The positive number is:"+positive_number);

System.out.println("The negatives number is:"+negative_number);

System.out.println("total is:"+total);

System.out.println("average is:"+avg);

}

}

}

Output:

Enter an integer, when done input 0: 22

2

1

4

0

The positive number is:4

The negatives number is:0

total is:29.0

average is:7.25

Explanation:

In the above program firstly we import the package for user input then we define a class that is main in this class we define the main method in the main method we define variable. Then we create a scanner class object for user input. In the number variable, we take multiple inputs from the user and also check that the user does not insert 0 at the starting of the program. To check this we use the condition statement that is a number equal to 0 then it will terminate the program. In the else part we first declare the loop that checks that inserted number is positive and negative and in this, we calculate the total of the numbers and at the end of the loop, we calculate the average of the number and print all the values.

4 0
3 years ago
Read 2 more answers
Zahid needs to ensure that the text flows around an image instead of the image being placed on a separate line as the text. Whic
erica [24]

Answer:

I believe the answer is He can't do this on the layout dialog box

Explanation:

You use the format tab for text wrapping.

( Sorry if I'm wrong )

7 0
3 years ago
Read 2 more answers
Select the processes that help to create a program.
Marina86 [1]

Debugging ..............

4 0
3 years ago
The person who follows me first will be marked branliset and will be followed by me​
irga5000 [103]
I follow you
Hi how are u
6 0
3 years ago
Read 2 more answers
Other questions:
  • What are the main differences between a workgroup and a domain?
    14·2 answers
  • Define an I/O port. Which functions are performed by it?
    10·1 answer
  • Which command is not one of the available Change Case options?
    11·1 answer
  • What is the purpose of a mail merge field.
    14·1 answer
  • The blue bar across the top of the screen informs you of the Screen Title, or what step you are on.
    5·1 answer
  • How do i move a file in python3
    10·1 answer
  • In PowerPoint, a type of chart that, rather than showing numerical data, illustrates a relationship or logical flow between diff
    13·1 answer
  • What are the oop concept of java
    5·2 answers
  • Where in PowerPoint should a user navigate to complete the tasks listed below?
    6·1 answer
  • he superclass Student contains: a constructor that accepts a String corresponding to the name of the school the student attends
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!