EADST

Python: Generate No Repeat Random Integers

Python: Generate No Repeat Random Integers

import random
numbers = random.sample(range(1, 11), 10) # range [1,11)

[9, 4, 2, 8, 1, 7, 3, 10, 5, 6]

相关标签
About Me
XD
Goals determine what you are going to be.
Category
标签云
站点统计

本站现有博文266篇,共被浏览440645

本站已经建立2019天!

热门文章
文章归档
回到顶部