can some tell me where is the duplicate class in this program .and how to correct it
this program is telling me that there are duplicate classes and I am not seeing any
package calculator;
import javax.swing.*;
import java.awt.event.*;
public class Calculator extends JFrame implements ActionListener{
JTextField CoA, CoB, CoC;
JLabel Root1, Root2;
JLabel CoAx, CoBx, CoCx, Root1x, Root2x;
JButton calculateB, exitB;
CalButton cbHandler;
ExitButton exitButton;
public Calculator() {
setTitle("Quadratic Calculator");
CoAx = new JLabel("a", SwingConstants.CENTER);
CoBx = new JLabel("b", SwingConstants.CENTER);
CoCx = new JLabel("c", SwingConstants.CENTER);
Root1x = new JLabel("Root1", SwingConstants.CENTER);
Root2x = new JLabel("Root2", SwingConstants.CENTER);
CoA = new JTextField(10);
CoB = new JTextField(10);
CoC = new JTextField(10);
Root1 = new JLabel("", SwingConstants.RIGHT);
Root2 = new JLabel("", SwingConstants.RIGHT);
calculateB = new JButton("Calculate");
cbHandler = new CalculateButtonHandler();
calculateB.addActionListener(cbHandler);
//Create Exit Button
exitB = new JButton("Exit");
ebHandler = new ExitButton();
exitB.addActionListener(ebHandler);
Container pane = getContentPane();
pane.setLayout(new GridLayout(6, 2));
pane.add(CoAx);
pane.add(CoA);
pane.add(CoBx);
pane.add(CoB);
pane.add(CoCx);
pane.add(CoC);
pane.add(Root1x);
pane.add(Root1);
pane.add(Root2x);
pane.add(Root2);
pane.add(calculateB);
pane.add(exitB);
setSize(400, 300);
setVisible(true);
setDefaultCloseOperation(EXIT_ON_CLOSE);
}
private class CalButton implements ActionListener
{
@Override
public void actionPerformed(ActionEvent e) {
double a = Double.parseDouble(CoA.getText());
double b = Double.parseDouble(CoB.getText());
double c = Double.parseDouble(CoC.getText());
double det = (4 * a * c);
b = b * b;
double R1 = Math.sqrt(b + det);
double R2 = Math.sqrt(b - det);
Root1.setText("" + R1);
Root2.setText("" + R2);
}
}
private class ExitsButton implements ActionListener{
@Override
public void actionPerformed(ActionEvent e) {
System.exit(0);
}
}
public static void main ( String[] args)
{
Calculator cal = new Calculator();
}
}

