public class Random extends Object
| Constructor and Description |
|---|
Random(long seed)
Create a new instance of
Random and initialize it with the given seed. |
| Modifier and Type | Method and Description |
|---|---|
float |
nextFloat()
Generate a uniformly distributed floating-point number in the half-open range [0, 1).
|
int |
nextInt(int n)
Generate a uniformly distributed integer in the half-open range [0, n).
|
public Random(long seed)
Random and initialize it with the given seed.seed - the seed numberpublic float nextFloat()
public int nextInt(int n)
n - the upper limit (exclusive) of the generated integerCopyright © 2015–2019 JOML. All rights reserved.