Home
last modified time | relevance | path

Searched refs:nsmallest (Results 1 – 9 of 9) sorted by relevance

/third_party/python/Lib/test/
Dtest_heapq.py231 self.assertEqual(list(self.module.nsmallest(n, data)),
233 self.assertEqual(list(self.module.nsmallest(n, data, key=f)),
384 self.module.nlargest, self.module.nsmallest):
392 for f in (self.module.nlargest, self.module.nsmallest):
401 for f in (self.module.nlargest, self.module.nsmallest):
407 self.module.nlargest, self.module.nsmallest):
411 for f in (self.module.nlargest, self.module.nsmallest):
/third_party/python/Lib/
Dheapq.py461 def nsmallest(n, iterable, key=None): function
/third_party/python/Doc/library/
Dheapq.rst120 .. function:: nsmallest(n, iterable, key=None)
Dfunctools.rst117 :func:`max`, :func:`heapq.nlargest`, :func:`heapq.nsmallest`,
Dfunctions.rst1056 such as ``sorted(iterable, key=keyfunc)[0]`` and ``heapq.nsmallest(1,
/third_party/python/Doc/whatsnew/
D2.5.rst1361 * The :func:`nsmallest` and :func:`nlargest` functions in the :mod:`heapq`
1368 >>> heapq.nsmallest(2, L) # Return two lowest elements, lexicographically
1370 >>> heapq.nsmallest(2, L, key=len) # Return two shortest elements
D2.4.rst1080 :func:`nsmallest` that use heaps to find the N largest or smallest values in a
/third_party/python/Doc/
Dglossary.rst686 :func:`heapq.nsmallest`, :func:`heapq.nlargest`, and
/third_party/python/Misc/
DHISTORY15773 - Issue #4790: The nsmallest() and nlargest() functions in the heapq module
19334 - heapq.nsmallest() and heapq.nlargest() now support key= arguments with
20854 - heapq.py has two new functions, nsmallest() and nlargest().