首页
it技术
登录
6mi
u
盘
搜
搜 索
it技术
如何将30个数随机排列
如何将30个数随机排列
it
2023-09-15
79
import
random
import
numpy
as
np arr
=
[
]
;
i
=
1
;
while
len
(
arr
)
<
30
:
x
=
random
.
randint
(
0
,
30
)
;
if
x
not
in
arr
:
arr
.
append
(
x
)
else
:
pass
print
(
arr
)
转载请注明原文地址: https://lol.8miu.com/read-9065.html
最新回复
(
0
)