import java.awt.*; import java.awt.event.*; import javax.swing.*; public class Mine extends JFrame implements ActionListener, MouseListener{ int nomines = 80; int perm[][]; String tmp; boolean found = false; int row; int column; int guesses[][]; JButton b[][]; int[][] mines; boolean allmines; int n = 30; int m = 30; int deltax[] = {-1, 0, 1, -1, 1, -1, 0, 1}; int deltay[] = {-1, -1, -1, 0, 0, 1, 1, 1}; double starttime; double endtime; public Mine(){ this.setDefaultCloseOperation(EXIT_ON_CLOSE); perm = new int[n][m]; boolean allmines = false; guesses = new int [n+2][m+2]; mines = new int[n+2][m+2]; b = new JButton [n][m]; setLayout(new GridLayout(n,m)); for (int y = 0;y