fork(1) download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. import java.util.concurrent.ThreadLocalRandom ;
  8.  
  9. /* Name of the class has to be "Main" only if the class is public. */
  10. class Ideone
  11. {
  12. public static void main (String[] args) throws java.lang.Exception
  13. {
  14. int low = 7 ;
  15. int high = 42 ;
  16.  
  17. int[] randInts = ThreadLocalRandom.current().ints( low , high ).limit( 100 ).toArray() ;
  18.  
  19. System.out.println(
  20. Arrays.toString( randInts )
  21. ) ;
  22. }
  23. }
Success #stdin #stdout 0.07s 50776KB
stdin
Standard input is empty
stdout
[15, 8, 21, 24, 9, 9, 38, 32, 41, 30, 31, 18, 33, 27, 11, 17, 17, 9, 10, 38, 24, 30, 23, 15, 33, 41, 7, 14, 34, 40, 10, 41, 16, 30, 9, 25, 24, 10, 16, 28, 25, 11, 27, 12, 20, 20, 40, 39, 14, 7, 8, 26, 33, 26, 34, 22, 40, 16, 30, 17, 29, 37, 23, 36, 18, 10, 22, 9, 7, 12, 31, 22, 21, 38, 37, 35, 39, 38, 14, 40, 31, 31, 40, 12, 10, 11, 15, 19, 16, 15, 25, 20, 8, 32, 41, 7, 20, 17, 37, 23]