Python中怎么随机输出一个字符串

2025-03-09 09:38:07
推荐回答(1个)
回答1:

import random
ret = random.randint(0, 3)

这样就可以得到[0, 3]中的随机数了。