python中randint函数的使用方法

python中randint函数的用法是:

官方文档中给出的用法是:numpy.random.randint(low,high=None,size=None,dtype)

生成在半开半闭区间[low,high)上离散均匀分布的整数值;若high=None,则取值区间变为[0,low)

用法及实现

high=None的情形

python中randint函数的使用方法

high≠None

python中randint函数的使用方法

以上就是python中randint函数的用法是什么?的详细内容,更多请关注其它相关文章!