这是一个Python代码示例,可以生成70个300-600之间的随机数:

import random

numbers = []
for i in range(70):
    number = random.randint(300, 600)
    numbers.append(number)

print(numbers)

输出的结果类似于:

[332, 557, 505, 488, 450, 453, 380, 398, 557, 449, 342, 321, 415, 581, 490, 569, 542, 491, 455, 599, 417, 503, 594, 560, 593, 387, 532, 390, 450, 514, 401, 535, 357, 558, 477, 372, 596, 348, 570, 365, 544, 300, 445, 345, 414, 546, 502, 475, 585, 444, 455, 415, 406, 587, 431, 343, 427, 541, 515, 465, 357, 572, 477, 445, 474, 542, 359, 475, 453, 528]
``
随机生成70个300-600之间的数字

原文地址: https://www.cveoy.top/t/topic/eOtI 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录