public static void main(String[] args) throws FileNotFoundException {
		JFileChooser chooser = new JFileChooser(new File(System.getProperty("user.dir"))); // Create the FileChooser instance 
		int returnVal = chooser.showOpenDialog(null);
		
		GameOfLife gol;
		if(returnVal != JFileChooser.APPROVE_OPTION)
			gol = new GameOfLife(gridSize); // Create random game if the user dismiss the dialog
		else
			gol = new GameOfLife(openMatrix(chooser.getSelectedFile().getPath())); // Read the initial state from a file
		System.out.println(gol); // Print the state as a matrix
		
		/*GameOfLife gol = new GameOfLife(initialState); // Use the array above to set the initial state
		gridSize = initialState[0].length;*/
		
		StdDraw.setCanvasSize(700, 700); // Adjust the size of the window
		StdDraw.setBorder(0.10); // We added this function ourself in order to adjust the border size
		StdDraw.setScale(0, gridSize-1); // Set size of the coordinate system
		StdDraw.setPenRadius(1.0/(double)gridSize);
		StdDraw.setPenColor(Color.BLACK);
		
		for(int i = 1; i <= 500; i++) {
			StdDraw.show(0);
			StdDraw.clear();
			
			for(int y = 0; y < gridSize; y++) {
				for(int x = 0; x < gridSize; x++) {
					if(gol.getState(x, y) == 1)
						StdDraw.point(x, y);
				}
			}
			StdDraw.show(50); // Sleep for 50ms
			gol.nextState();
		}
	}