public Board(int N, double probability) {
        size = N;
        board = new Cell[N][N];
        for (int x = 0; x < N; x++) {
            for (int y = 0; y < N; y++) {
                if (Math.random() < probability) {
                    board[x][y] = new Cell(x, y, true);
                } else {
                    board[x][y] = new Cell(x, y, false);
                }
            }
        }
    }