294 |
|
* @throws IllegalArgumentException if n is not positive |
295 |
|
* @since 1.2 |
296 |
|
*/ |
297 |
– |
|
297 |
|
public int nextInt(int n) { |
298 |
|
if (n <= 0) |
299 |
|
throw new IllegalArgumentException("n must be positive"); |
367 |
|
* range {@code 0.0f} (inclusive) to {@code 1.0f} (exclusive), is |
368 |
|
* pseudorandomly generated and returned. All 2<font |
369 |
|
* size="-1"><sup>24</sup></font> possible {@code float} values |
370 |
< |
* of the form <i>m x </i>2<font |
370 |
> |
* of the form <i>m x </i>2<font |
371 |
|
* size="-1"><sup>-24</sup></font>, where <i>m</i> is a positive |
372 |
|
* integer less than 2<font size="-1"><sup>24</sup> </font>, are |
373 |
|
* produced with (approximately) equal probability. |