Thanks, I finally got it compiled, however now I'm getting errors about no
definition class. I'm getting the same message for both my class file and
the actual program.
import javax.swing.JOptionPane;
public class Circleprogram
{
public static void main (String[]args)
{
double number, area, circumference, diameter, radius;
String input;
Circle info = new Circle();
input= JOptionPane.showInputDialog("What is the radius");
number = Double.parseDouble(input);
info.setRadius(number);
radius= info.getRadius();
area = info.getArea();
diameter = info.getDiameter();
circumference = info.getCircumference();
JOptionPane.showMessageDialog(null, "The area is" + area +
", the circumference is" + circumference +
", the diameter" + diameter + ", and the radius is " +
radius);
System.exit(0);
}
}
this is the actual program
|