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
Lunna [17]
3 years ago
7

Create a class named Circle with fields named radius, diameter, and area. Include a constructor that sets the radius to 1 and ca

lculates the other two values. Also include methods named setRadius() and getRadius(). The setRadius() method not only sets the radius, but it also calculates the other two values. (The diameter of a circle is twice the radius, and the area of a circle is pi multiplied by the square of the radius. Use the Math class PI constant for this calculation.) Save the class as Circle.java.
Computers and Technology
1 answer:
REY [17]3 years ago
6 0

Answer:

The code for this class is shown in the explanation section

Explanation:

public class Circle {

   private double radius;

   private double diameter;

   private double area;

   public Circle(double radius, double diameter, double area) {

       this.radius = 1;

       this.diameter = diameter;

       this.area = area;

   }

   public void setRadius(double radius) {

       this.radius = radius;

       diameter = radius*2;

       area= Math.PI*(radius*radius);

   }

   public double getRadius() {

       return radius;

   }

}

You might be interested in
Who all likes fortnite
Debora [2.8K]

Answer:

my brother

Explanation:

5 0
3 years ago
Read 2 more answers
If the three operations were combined, O(logN) + O(N) * O(logN) + 1, the overall algorithm cost would be:________
KiRa [710]

Answer:

D. O(NlogN)

Explanation:

The computation of the overall algorithm cost is as follows:

Given that

O(logN) + O(N) × O(logN) + 1

In the case of complexity we considered the high order that dominates the other terms

Thus, that term would be  

O(N) × O(logN)

It could be rewrite as

O(NlogN)

Hence, the correct option is D.

All the other options are wrong

3 0
3 years ago
Which subscription service complements App-ID by enabling you to configure the next-generation firewall to identify and control
Nataly [62]

The subscription service that complements App-ID by enabling you to configure the firewall to identify and control access to websites is  URL Filtering.

<h3>What is URL filtering?</h3>

The term URL filtering is known to function by looking at the similarities of all web traffic against a given URL filters.

Note that it is one that is made up of database of sites that users do access and as such, the subscription service that complements App-ID by enabling you to configure the firewall to identify and control access to websites is  URL Filtering.

Learn more about subscription from

brainly.com/question/14073216

#SPJ1

4 0
2 years ago
Which statement best explains taxation without representation was a major issue for colonists?
Sauron [17]
Taxation without representation was a major issue for the colonists, because they were being unfairly taxed by the British without having a representative in the British Parliament to represent them ans state that they were against this. It was also one of the driving forces of the American Revolution, as it was just one of the grievances the colonists were experiencing from the British. 
4 0
3 years ago
Does a 21.6v battery work with a 24 volt controller
Mila [183]
Yes but you will need more than one battery
3 0
3 years ago
Other questions:
  • What is the formula equivalent to the function =SUM(B1:B5)?
    11·2 answers
  • Which statement is true of Web-based electronic data interchange (Open EDI)? a. It consists of international agreements on priva
    7·1 answer
  • What test is most similar to binary​
    9·1 answer
  • What is one of the most effective security tools available for protecting users from external threats?
    15·1 answer
  • Is your florida learners license number the same as the actual license number?
    14·2 answers
  • Which of the following code segments does not contain any errors?
    7·1 answer
  • What is the TAG to begin a Web page, as recommended by the W3C?
    13·1 answer
  • Which statement is NOT CORRECT?
    11·1 answer
  • The chief intellectual property officer (CIPO) is responsible for collecting, maintaining, and distributing the organization's k
    14·1 answer
  • What is the long tube on a microscope called​
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!