Online Java Compiler By
JavaTpoint.com
import java.util.concurrent.ThreadLocalRandom; public class ThreadLocalRandomLongsExample2 { public static void main(String[] args) { // Returns a stream of pseudorandom long values System.out.println("stream of pseudorandom long value is: " +ThreadLocalRandom.current().longs(20, 30)); } }
Output