//ComputeArea.java:Compute the area of a circle
public class ComputeArea {
public static void main(String[] args){
double PI = 3.14159;
double radius = 20;
//Compute area
double area = radius * radius * PI;
//Display result
System.out.println("The area for the circle of radius," + radius + "is," + area);
}
}
public class ComputeArea {
public static void main(String[] args){
double PI = 3.14159;
double radius = 20;
//Compute area
double area = radius * radius * PI;
//Display result
System.out.println("The area for the circle of radius," + radius + "is," + area);
}
}
Thanks guys.
ReplyDeletefeel free to ask any help u need related to IT