fork(29) download
  1. import java.util.*;
  2. import java.lang.*;
  3.  
  4. class Main
  5. {
  6. public static void main (String[] args) throws java.lang.Exception
  7. {
  8. Random random = new Random(1234567);
  9. int min = 5;
  10. int max = 20;
  11. while (true) {
  12. int x = (int)(Math.random() * max) + min;
  13. System.out.println(x);
  14. if (x < min || x >= max) { break; }
  15. }
  16. }
  17. }
Success #stdin #stdout 0.05s 213440KB
stdin
Standard input is empty
stdout
10
16
13
21