How to remove action listener? Java

This is very crude code, I’m trying to remove an action listener here because whenever I press the new button twice, it adds in another action listener and breaks my code. I’d like for it just to add a new action listener whenever I click new and remove it when it is done with it.

Currently, this code works completely except for the remove action listener bit, which gives the error Can only iterate over an array or an instance of java.lang.Iterable when I hover over “btnGuess” in the line for( JButton currentButton: btnGuess ) {

btnNew.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent e) {
        int random = (int) Math.floor(Math.random() * (max - min + 1) + min);
        lblQuestion.setText("What is the symbol of " + elements[random]);
        btnGuess.addActionListener(new ActionListener() {
            int correct = 0, incorrect = 0, limit = 0;
            public void actionPerformed(ActionEvent e) {
                String correctanswers = symbols[random];
                String userAnswer = getUserAnswer();
                String answer = "";
                System.out.println("user " + userAnswer);
                System.out.println("correct " + correctanswers);
                if (userAnswer.equals(correctanswers)) {
                    answer = "Correct";
                    correct = correct + 1;
                } else {
                    answer = "Incorrect";
                    incorrect = incorrect + 1;
                }
                lblcountcorrect.setText(String.valueOf(correct));
                lblcountincorrect.setText(String.valueOf(incorrect));
                lblFeedback.setText("You were " + answer);
            }
        });
    }
});

for (JButton currentButton: btnGuess) {
    for (ActionListener al: currentButton.getActionListeners()) {
        currentButton.removeActionListener(al);
    }
}

Edit:
Here is my updated code to the full:
As you can see, the console shows 2 more new outputs but keeps the 2 old ones everytime you click new. This also messes with my counter and correct/incorrect output.

package SwingPrograms;

import java.io.*;
import java.lang.Iterable;

import java.awt.BorderLayout;
import java.awt.EventQueue;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import javax.swing.JButton;
import javax.swing.JTextField;
import javax.swing.SwingConstants;
import javax.swing.JLabel;
import java.awt.Font;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.Color;

public class periodicTable extends JFrame {

    private JPanel contentPane;
    private JTextField textBoxGuess;

    /**
     * Launch the application.
     */
    public static void main(String[] args) {
        EventQueue.invokeLater(new Runnable() {
            public void run() {
                try {
                    periodicTable frame = new periodicTable();
                    frame.setVisible(true);
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        });

    }

    /**
     * Create the frame.
     */

    public periodicTable() {
        
        String[] elements = goReadTextFile("C:\\Users\\Allan\\Documents\\1 java\\elements.txt");
        String[] symbols = goReadTextFile("C:\\Users\\Allan\\Documents\\1 java\\symbols.txt");
        int correct = 0, incorrect = 0;
        //when button "next" is clicked come back here
        int min = 1, max = elements.length;
        
        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        setBounds(100, 100, 1067, 742);
        contentPane = new JPanel();
        contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
        setContentPane(contentPane);
        contentPane.setLayout(null);
        
        
        JLabel lblQuestion = new JLabel("What is the symbol of ", SwingConstants.CENTER);
        lblQuestion.setFont(new Font("Tahoma", Font.BOLD, 40));
        lblQuestion.setBounds(10, 11, 1031, 110);
        contentPane.add(lblQuestion);
        
        
        JButton btnNew = new JButton("NEW");
        /*btnNew.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                int random = (int)Math.floor(Math.random()*(max-min+1)+min);
    
                lblQuestion.setText("What is the symbol of " + elements[random]);
                String correctanswers = symbols[random];
            }

        });*/
        btnNew.setFont(new Font("Tahoma", Font.BOLD, 50));
        btnNew.setBounds(315, 114, 162, 49);
        contentPane.add(btnNew);
        
        textBoxGuess = new JTextField();
        textBoxGuess.setFont(new Font("Tahoma", Font.BOLD, 99));
        textBoxGuess.setBounds(296, 174, 205, 100);
        contentPane.add(textBoxGuess);
        textBoxGuess.setColumns(10);
        
        JButton btnGuess = new JButton("SUBMIT");
        btnGuess.setFont(new Font("Tahoma", Font.BOLD, 50));
        btnGuess.setBounds(544, 203, 241, 49);
        contentPane.add(btnGuess);
          
        JLabel lblFeedback = new JLabel("You were ");
        lblFeedback.setFont(new Font("Tahoma", Font.BOLD, 40));
        lblFeedback.setBounds(315, 398, 470, 60);
        contentPane.add(lblFeedback);
        
        
        JLabel lblcorrect = new JLabel("Correct Answers");
        lblcorrect.setForeground(Color.GREEN);
        lblcorrect.setFont(new Font("Tahoma", Font.BOLD, 20));
        lblcorrect.setBounds(36, 396, 172, 80);
        contentPane.add(lblcorrect);
        
        JLabel lblincorrect = new JLabel("Incorrect Answers");
        lblincorrect.setForeground(Color.RED);
        lblincorrect.setFont(new Font("Tahoma", Font.BOLD, 20));
        lblincorrect.setBounds(818, 402, 187, 69);
        contentPane.add(lblincorrect);
        
        JLabel lblcountcorrect = new JLabel(String.valueOf(correct));
        lblcountcorrect.setForeground(Color.GREEN);
        lblcountcorrect.setFont(new Font("Tahoma", Font.PLAIN, 99));
        lblcountcorrect.setBounds(36, 472, 172, 110);
        contentPane.add(lblcountcorrect);
        
        JLabel lblcountincorrect = new JLabel(String.valueOf(incorrect));
        lblcountincorrect.setForeground(Color.RED);
        lblcountincorrect.setFont(new Font("Tahoma", Font.PLAIN, 99));
        lblcountincorrect.setBounds(818, 487, 187, 95);
        contentPane.add(lblcountincorrect);
        

        btnNew.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                int random = (int)Math.floor(Math.random()*(max-min+1)+min);

                
                lblQuestion.setText("What is the symbol of " + elements[random]);

        btnGuess.addActionListener(new ActionListener() {   
            int correct=0,incorrect=0, limit=0;
            
            public void actionPerformed(ActionEvent e)            {
                String correctanswers = symbols[random];
                
                String userAnswer = getUserAnswer();
                String answer = "";
                System.out.println("user " + userAnswer);
                System.out.println("correct " + correctanswers);
                
                if (userAnswer.equals(correctanswers)) {
                    answer = "Correct";
                    correct=correct+1;
                }
                else {
                    answer = "Incorrect";
                    incorrect=incorrect+1;
                }
                
            lblcountcorrect.setText(String.valueOf(correct));
            lblcountincorrect.setText(String.valueOf(incorrect));
            lblFeedback.setText("You were " + answer);
        

            }
            
        }); 

            }

        });
        for( JButton currentButton: btnGuess ) {
            for( ActionListener al : currentButton.getActionListeners() ) {
                currentButton.removeActionListener( al );
            }
        }
    
        //need to figure out counter, and next button
    }
    
    
    public static String[] goReadTextFile(String Location) {
         String fileName = Location ;
           String line;
           int Count = 0;
           int length = 0;
           try
           {      
             BufferedReader in = new BufferedReader( new FileReader( fileName  ) ); //this code finds the length of the file, so can add new elements no hardcode length
             
             line = in.readLine();
             while ( line != null )  // while not end of file
             {
               length=length+1;
               line = in.readLine();
             }
             in.close();
           }
           catch(IOException iox) { 
               System.out.println("Problem reading " + fileName );
           }
           
           String[] temp = new String[length];
           try
           {      
             BufferedReader in = new BufferedReader( new FileReader( fileName  ) ); //this puts the txt file into a temp array
             
             line = in.readLine();
             while ( line != null )  // while not end of file
             {
            
               temp[Count]=line;
               Count=Count+1;
               line = in.readLine();
             }
             in.close();
           }
           catch ( IOException iox )
           {
             System.out.println("Problem reading " + fileName );
           }
        return temp;
    }
    
    
    public String getUserAnswer() {
        return textBoxGuess.getText();
    }
}

Once more another edit:
I have ammended my code thanks to the suggestions of the comments, it now works how I have intended except my correct/incorect counter has broken, any ideas how to fix it?

package SwingPrograms;

import java.io.*;
import java.lang.Iterable;

import java.awt.BorderLayout;
import java.awt.EventQueue;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import javax.swing.JButton;
import javax.swing.JTextField;
import javax.swing.SwingConstants;
import javax.swing.JLabel;
import java.awt.Font;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.Color;

public class periodicTable extends JFrame {

    private JPanel contentPane;
    private JTextField textBoxGuess;

    /**
     * Launch the application.
     */
    public static void main(String[] args) {
        EventQueue.invokeLater(new Runnable() {
            public void run() {
                try {
                    periodicTable frame = new periodicTable();
                    frame.setVisible(true);
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        });

    }

    /**
     * Create the frame.
     */

    public periodicTable() {
        
        String[] elements = goReadTextFile("C:\\Users\\Allan\\Documents\\1 java\\elements.txt");
        String[] symbols = goReadTextFile("C:\\Users\\Allan\\Documents\\1 java\\symbols.txt");
        int correct = 0, incorrect = 0;
        //when button "next" is clicked come back here
        int min = 1, max = elements.length;
        
        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        setBounds(100, 100, 1067, 742);
        contentPane = new JPanel();
        contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
        setContentPane(contentPane);
        contentPane.setLayout(null);
        
        
        JLabel lblQuestion = new JLabel("What is the symbol of ", SwingConstants.CENTER);
        lblQuestion.setFont(new Font("Tahoma", Font.BOLD, 40));
        lblQuestion.setBounds(10, 11, 1031, 110);
        contentPane.add(lblQuestion);
        
        
        JButton btnNew = new JButton("NEW");
        /*btnNew.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                int random = (int)Math.floor(Math.random()*(max-min+1)+min);
    
                lblQuestion.setText("What is the symbol of " + elements[random]);
                String correctanswers = symbols[random];
            }

        });*/
        btnNew.setFont(new Font("Tahoma", Font.BOLD, 50));
        btnNew.setBounds(315, 114, 162, 49);
        contentPane.add(btnNew);
        
        textBoxGuess = new JTextField();
        textBoxGuess.setFont(new Font("Tahoma", Font.BOLD, 99));
        textBoxGuess.setBounds(296, 174, 205, 100);
        contentPane.add(textBoxGuess);
        textBoxGuess.setColumns(10);
        
        JButton btnGuess = new JButton("SUBMIT");
        btnGuess.setFont(new Font("Tahoma", Font.BOLD, 50));
        btnGuess.setBounds(544, 203, 241, 49);
        contentPane.add(btnGuess);
          
        JLabel lblFeedback = new JLabel("You were ");
        lblFeedback.setFont(new Font("Tahoma", Font.BOLD, 40));
        lblFeedback.setBounds(315, 398, 470, 60);
        contentPane.add(lblFeedback);
        
        
        JLabel lblcorrect = new JLabel("Correct Answers");
        lblcorrect.setForeground(Color.GREEN);
        lblcorrect.setFont(new Font("Tahoma", Font.BOLD, 20));
        lblcorrect.setBounds(36, 396, 172, 80);
        contentPane.add(lblcorrect);
        
        JLabel lblincorrect = new JLabel("Incorrect Answers");
        lblincorrect.setForeground(Color.RED);
        lblincorrect.setFont(new Font("Tahoma", Font.BOLD, 20));
        lblincorrect.setBounds(818, 402, 187, 69);
        contentPane.add(lblincorrect);
        
        JLabel lblcountcorrect = new JLabel(String.valueOf(correct));
        lblcountcorrect.setForeground(Color.GREEN);
        lblcountcorrect.setFont(new Font("Tahoma", Font.PLAIN, 99));
        lblcountcorrect.setBounds(36, 472, 172, 110);
        contentPane.add(lblcountcorrect);
        
        JLabel lblcountincorrect = new JLabel(String.valueOf(incorrect));
        lblcountincorrect.setForeground(Color.RED);
        lblcountincorrect.setFont(new Font("Tahoma", Font.PLAIN, 99));
        lblcountincorrect.setBounds(818, 487, 187, 95);
        contentPane.add(lblcountincorrect);
        

        btnNew.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                int random = (int)Math.floor(Math.random()*(max-min+1)+min);

                
                lblQuestion.setText("What is the symbol of " + elements[random]);
                
        btnGuess.addActionListener(new ActionListener() {   
            int correct,incorrect;
            
            public void actionPerformed(ActionEvent e)            {
                String correctanswers = symbols[random];
                
                String userAnswer = getUserAnswer();
                String answer = "";
                System.out.println("user " + userAnswer);
                System.out.println("correct " + correctanswers);
                
                if (userAnswer.equals(correctanswers)) {
                    answer = "Correct";
                    correct++;
                }
                else {
                    answer = "Incorrect";
                    incorrect++;
                }
                
            lblcountcorrect.setText(String.valueOf(correct));
            lblcountincorrect.setText(String.valueOf(incorrect));
            lblFeedback.setText("You were " + answer);
        
            for( ActionListener al : btnGuess.getActionListeners() ) {
                btnGuess.removeActionListener( al );
            }
            }
    
        }); 

            }

        });
        
    }
    
    
    public static String[] goReadTextFile(String Location) {
         String fileName = Location ;
           String line;
           int Count = 0;
           int length = 0;
           try
           {      
             BufferedReader in = new BufferedReader( new FileReader( fileName  ) ); //this code finds the length of the file, so can add new elements no hardcode length
             
             line = in.readLine();
             while ( line != null )  // while not end of file
             {
               length=length+1;
               line = in.readLine();
             }
             in.close();
           }
           catch(IOException iox) { 
               System.out.println("Problem reading " + fileName );
           }
           
           String[] temp = new String[length];
           try
           {      
             BufferedReader in = new BufferedReader( new FileReader( fileName  ) ); //this puts the txt file into a temp array
             
             line = in.readLine();
             while ( line != null )  // while not end of file
             {
            
               temp[Count]=line;
               Count=Count+1;
               line = in.readLine();
             }
             in.close();
           }
           catch ( IOException iox )
           {
             System.out.println("Problem reading " + fileName );
           }
        return temp;
    }
    
    
    public String getUserAnswer() {
        return textBoxGuess.getText();
    }
}