0
Follow
0
View

Please help me to answer the question

dongchao_123 注册会员
2023-02-25 18:33
random = new Random(); for (int i = 0; newList.size()!=5 ; i++) { int randomNum = random.nextInt(5);// 生成0到4之间的随机整数 if (!newList.contains(stuNum[randomNum])){//如果新数组里没有这个序号,就添加到新数组里 newList.add(stuNum[randomNum]); } } System.out.println(newList); } .
< !- - - - - >

About the Author

Question Info

Publish Time
2023-02-25 18:33
Update Time
2023-02-25 18:33

Related Question

在Cytoscape JS中添加背景图像到边缘

“style.max-height.Px“不工作primeng p卡

pygame 矩形绘制问题

Magento2: Youtube视频产品细节页面自动播放

在DbCommandInterceptor中实现并拦截ReaderExecutingAsync

Java的primefile

模拟格式化的datetime.datetime.now()

POJ第3320出现Runtime Error

MELSOFT GX Works3

如何在pygame中顺利移动图像