2015-04-20 15:36:01 -07:00
|
|
|
|
//: interfaces/RandVals.java
|
2015-05-29 14:18:51 -07:00
|
|
|
|
// <20>2015 MindView LLC: see Copyright.txt
|
2015-04-20 15:36:01 -07:00
|
|
|
|
// Initializing interface fields with
|
|
|
|
|
// non-constant initializers.
|
|
|
|
|
import java.util.*;
|
|
|
|
|
|
|
|
|
|
public interface RandVals {
|
|
|
|
|
Random RAND = new Random(47);
|
|
|
|
|
int RANDOM_INT = RAND.nextInt(10);
|
|
|
|
|
long RANDOM_LONG = RAND.nextLong() * 10;
|
|
|
|
|
float RANDOM_FLOAT = RAND.nextLong() * 10;
|
|
|
|
|
double RANDOM_DOUBLE = RAND.nextDouble() * 10;
|
|
|
|
|
} ///:~
|