Removed duplicate code.

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1509236 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Gilles Sadowski 2013-08-01 13:55:22 +00:00
parent c97a18ad13
commit a846ced6e3
1 changed files with 1 additions and 9 deletions

View File

@ -37,14 +37,6 @@ public class JDKRandomGenerator extends Random implements RandomGenerator {
/** {@inheritDoc} */
public void setSeed(int[] seed) {
// the following number is the largest prime that fits in 32 bits (it is 2^32 - 5)
final long prime = 4294967291l;
long combined = 0l;
for (int s : seed) {
combined = combined * prime + s;
}
setSeed(combined);
setSeed(RandomGeneratorFactory.convertToLong(seed));
}
}