random.sample(range(1,N), k)表示从[1,N]的范围内随机生成k个数,结果以列表返回栗子1: 随机生成5个(1, 10)范围内的数字:import randomfor i in ...
確定! 回上一頁