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
Yakvenalex [24]
3 years ago
9

Create a class Circle with one instance variable of type double called radius. Then define an appropriate constructor that takes

an initial value for the radius, get and set methods for the radius, and methods getArea and getPerimeter.
Computers and Technology
1 answer:
Mrrafil [7]3 years ago
4 0

public class Circle {

// the private data members

private double radius;

private double area;

private double diameter;

public void setRadius(double r)

{

 radius = r;

}

public double getRadius()

{

 return radius;

}

public double computeDiameter()

{

 return radius * 2;

}

public double computeArea()

{

 return ((radius * radius) * 3.14);

}

}

You might be interested in
Part of the central processing unit
AveGali [126]

Answer:

Explanation:

The arithmetic logic unit (ALU) performs mathematical, logical, and decision operations.  It can be divided into the arithmetic unit (responsible for addition, subtraction, multiplication and division).  And logic unit (responsible for comparing, selecting, matching and merging different data or information).  The power and efficiency of the CPU depends on the design of the ALU.  

Next up is the control unit (CU) which directs all the processor’s operations.  It’s where the CPU reads and interprets requests from memory and transforms them into a series of signals (binary).  Then it sends the operation to various parts of the laptop as instructed.  The CU calls the ALU to perform the necessary calculations.  It also coordinates all input/output devices to transfer or receive instructions.

The main job of the memory unit is to store data or instructions and intermediate results.  It’s divided into primary memory and secondary memory to supply data to other units of the CPU.  It allows the CPU to perform functions requested by programs like the operating system without having to ask RAM.

Another element of the CPU not depicted in the diagram is transistors.  To carry out calculations, binary information (ones and zeros) is stored in these microscopic switches.  They control the flow of electricity depending on whether the switch is ON or OFF.  Signals turn off and on different combinations of transistors to perform calculations.  A very thin silicon chip can contain several hundred million transistors.

8 0
2 years ago
Is(are) input value(s) to use with a program to test the accuracy of the output.
Law Incorporation [45]

Answer:

test cases

Explanation:

5 0
2 years ago
Read 2 more answers
What are the functions of the windows button, Task View and Search Box? give me short answer
artcher [175]

Answer:

Windows button = You can see a Start Menu

Task view = You can view your Tasks

Search Box = You can search any app you want in an instance

6 0
3 years ago
Consider a hard disk with the following specifications :<br> 3.5 in diameter
AnnyKZ [126]

Answer:

usable capacity = 10 GB

Number of cylinders = 256

Block size = 4 KB

(1)Bytes in each cylinder = (10*230)/(256) = (10*222) = 40 MegaBytes

(2)Number of Blocks in each cylinder = (10*222)/(212) = 10K

(3)capacity of one track = 40 MegaBytes/(10*2) = 2 MB

Rotation speed = 3840 RPM

Number of rotations per second = 3840/60 = 64

Transfer rate = (2*64) = 128 MB/sec

Explanation:

6 0
3 years ago
MARKING BRAINLIEST
BabaBlast [244]

Answer: Well, first of all, you might want to change websites. I suggest khan academy.

anyways if your a begnner *Like me* The you might wanna try Java Script! in other words i do not know how to work Python

8 0
3 years ago
Other questions:
  • The collection of all possible vulnerabilities that could provide unauthorized access to computer resources is called the:
    12·1 answer
  • A person painting his house dumps the unused paint on the ground. Which of the following resources will this most likely pollute
    14·1 answer
  • Given the following code segment, what is output after "result = "? int x = 1, y = 1, z = 1; y = y + z; x = x + y; cout &lt;&lt;
    7·1 answer
  • he fundamental building block in every Hypertext Markup Language (HTML) document is the _____ tag, which marks a component in th
    7·1 answer
  • What is the purpose of exporting your public key to the directory services server?
    11·1 answer
  • Select the correct answer.
    10·1 answer
  • Write a program that accepts two integers from the user and perform one of the four arithmetic operations based on user’s choice
    11·1 answer
  • Tommy loves taking care of homing pigeons. He sent a note to his crush who lives 24.0 km away from his house. These birds fly at
    9·1 answer
  • How is it possible for the router to know whether it is supposed to send a cat photo to your laptop
    5·1 answer
  • I need the full code for 6.1.3 code hs circles and squares please answer please help
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!