mirror of
https://github.com/LingCoder/OnJava8.git
synced 2026-08-24 06:53:27 +08:00
@@ -54,7 +54,7 @@ public class ImperativeRandoms {
|
||||
Random rand = new Random(47);
|
||||
SortedSet<Integer> rints = new TreeSet<>();
|
||||
while(rints.size() < 7) {
|
||||
int r = rand.nextint(20);
|
||||
int r = rand.nextInt(20);
|
||||
if(r < 5) continue;
|
||||
rints.add(r);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user