输出圆的面积的Java程序
public class ComputerCircleArea{
public static void main(String args[]){
double radius;
double area;
radius=163.16;
area=3.14*radius*radius;
System.out.printf("半径是%5.3f的圆的面积:\n%5.3f\n",radius,area);
}
}
public class ComputerCircleArea{
public static void main(String args[]){
double radius;
double area;
radius=163.16;
area=3.14*radius*radius;
System.out.printf("半径是%5.3f的圆的面积:\n%5.3f\n",radius,area);
}
}