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;
}
}
Avoid wikipedia, anyone can put answers down on there and make it seem correct but it is not. Do not trust any website research the websites or look at ratings if possible. Use the answers that google provides itself if possible. And research trusted websites.
If this helped please mark me as brainlest.
Answer: Within other member
Explanation:
The private data member is also known as private function in the computer programming language. The private keyword is basically used to specify the access level and also provide the variable and the methods control to the programmers in the class.
In the class, the variables and the method are directly access by the other methods with the same class but not directly access by the derived class. Therefore, the private members of the class are easily access from the other member of the similar class and also from friends.
num = float(input("Enter a number: "))
num1 = int(num)
print(num - num1)
I hope this helps!
The answer is compact disc or cd, only device that use lasers (that arent proprietary floppys)