FRQ4
public class LightBoard {
private boolean[] [] lights;
public LightBoard(int numRows, int numCols) {
lights = new boolean[numRows][numCols];
for (int i=0; i<numRows; i++) {
for (int j=0; j<numCols; j++) {
java.util.Random random = new java.util.Random();
double r = random.nextDouble();
if (r < 0.4) {
lights[i][j] = true;
}
else {
lights[i][j] = false;
}
}
}
}
}
public boolean evalulateLight(int row, int col) {
}