title: GUI buttons in array
body: <p>I am working on a project and we are learning arrays. I need to create a GUI that has 12 buttons but need to be in an array. I am not finished with my code, so it may have errors because of that.</p>
  
  <p>Where I am getting an error is on my </p>
  
  <pre><code>JButton[] = { new Jbutton("1"), ...}; 
  </code></pre>
  
  <p>the 2nd ] has a red line under it and gives me the error </p>
  
  <pre><code>Syntax error on token "]" VariableDeclaratorld expected after this token
  </code></pre>
  
  <p>Heres my code so far:</p>
  
  <pre><code>public class TextButtonsHW extends JFrame implements ActionListener {
  private JButton[] buttons;  
  private JTextArea textArea; 
  private final int ENTER;    
  private final int SPACE;    
  private final int CLEAR;    
  
  public TextButtonsHW(String title) {
      super(title); 
      JButton[] = { new JButton("A"), new JButton("B"), new JButton("C"),
                    new JButton("1"), new JButton("2"), new JButton("3"),
                    new JButton("X"), new JButton("Y"), new JButton("Z"),
                    new JButton("Enter"), new JButton("Space"), new JButton("Clear")};
      }
  }
  </code></pre>