open fun nextLong(): Long
fun nextLong(): Long
Gets the next random Long
from the random number generator.
Generates a Long
random value uniformly distributed between Long.MIN_VALUE
and Long.MAX_VALUE
(inclusive).
open fun nextLong(until: Long): Long
fun nextLong(until: Long): Long
Gets the next random non-negative Long
from the random number generator less than the specified until bound.
Generates a Long
random value uniformly distributed between 0
(inclusive) and the specified until bound (exclusive).
until
- must be positive.
IllegalArgumentException
- if until is negative or zero.
open fun nextLong(from: Long, until: Long): Long
fun nextLong(from: Long, until: Long): Long
© 2010–2020 JetBrains s.r.o. and Kotlin Programming Language contributors
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.random/-random/next-long.html