[Solved] SOLVED:LAB circle and Circle Driver

30 $

File Name: SOLVED:LAB_circle_and_Circle_Driver.zip
File Size: 329.7 KB

SKU: [Solved] SOLVED:LAB circle and Circle Driver Category: Tag:

Or Upload Your Assignment Here:


Create a java class Circle as described below: radius: a double PI: a final double initialized with the value 3.14159 The class should have the following methods: calculateArea – Returns the area of the circle, which is calculated as: area = PI * radius * radius calculateDiameter – Returns the diameter of the circle, which is calculated as: diameter = radius * 2 calculateCircumference – Returns the circumference of the circle, which is calculated as: circumference = 2 * PI * radius setRadius – A mutator (setter) method for the radius field getRadius – An accessor (getter) method for the radius field Create test data and calculate the expected result. Input Expected Results Radius Area Diameter Circumference – – – – – – – – – – – – Write a program name CircleDriver that demonstrates the Circle class by asking the user for the circle’s radius, creating a Circle object, and then reporting the circle’s area, diameter, and circumference.

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] SOLVED:LAB circle and Circle Driver
30 $