MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / uniform

Function uniform

tools/python-3.11.9-amd64/Tools/demo/sortvisu.py:362–365  ·  view source on GitHub ↗
(array)

Source from the content-addressed store, hash-verified

360# Various (un)sorting algorithms
361
362def uniform(array):
363 size = array.getsize()
364 array.setdata([(size+1)//2] * size)
365 array.reset("Uniform data, size %d" % size)
366
367def distinct(array):
368 size = array.getsize()

Callers 2

_sample_weightedFunction · 0.85
_sample_weightedFunction · 0.85

Calls 3

setdataMethod · 0.80
getsizeMethod · 0.45
resetMethod · 0.45

Tested by

no test coverage detected