### Question:
NormalRandomNumberGenerator implements RandomNumberGenerator { @Override public List<double[]> getVectors(int arraySize, int listSize) { ArgChecker.notNegative(arraySize, "arraySize"); ArgChecker.notNegative(listSize, "listSize"); List<double[]> result = new ArrayList<>(listSize); double[] x; for (int i = 0; i < listSize; i++) { x = new double[arraySize]; for (int j = 0; j < arraySize; j++) { x[j] = normal.nextRandom(); } result.add(x); } return result; } NormalRandomNumberGenerator(double mean, double sigma);  NormalRandomNumberGenerator(double mean, double sigma, RandomEngine engine); @Override double[] getVector(int size); @Override List<double[]> getVectors(int arraySize, int listSize);  }### Answer:
@Test public void test_list() { List<double[]> result = GENERATOR.getVectors(10, 50); assertThat(result).hasSize(50); for (double[] d : result) { assertThat(d.length).isEqualTo(10); } }
@Test public void test_invalid() { assertThatIllegalArgumentException() .isThrownBy(() -> new NormalRandomNumberGenerator(0, -1)); assertThatIllegalArgumentException() .isThrownBy(() -> new NormalRandomNumberGenerator(0, -1, new MersenneTwister64())); assertThatIllegalArgumentException() .isThrownBy(() -> new NormalRandomNumberGenerator(0, 1, null)); assertThatIllegalArgumentException() .isThrownBy(() -> GENERATOR.getVectors(-1, 4)); assertThatIllegalArgumentException() .isThrownBy(() -> GENERATOR.getVectors(1, -5)); }