求圆的面积和周长
public class Circle {
Scanner scanner = new Scanner(System.in);
int r = scanner.nextInt();
double s,c;
final double PI=3.1415926;
public void space()
{
s=PI*r*r;
System.out.println("圆的面积是:" + s);
}
public void circumference()
{
c=2*PI*r;
System.out.println("圆的周长是:" + c);
}
public static void main(String[] args){
Circle C = new Circle;
C.space();
C.circumference();
}
}