]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
Issue #23549: Clarify confusion in heapq doc - accessing the mininmal element
authorEli Bendersky <eliben@gmail.com>
Sun, 15 Mar 2015 03:14:23 +0000 (20:14 -0700)
committerEli Bendersky <eliben@gmail.com>
Sun, 15 Mar 2015 03:14:23 +0000 (20:14 -0700)
commit39430daa3b82a121b80633436170d0e0757f0fac
treed68ee66f628bc242b81285f673ee11eabba7a7a1
parenta785dece572e7f2bcc8a10aab3a661208e94583e
Issue #23549: Clarify confusion in heapq doc - accessing the mininmal element

The current documentation only mentions heap[0] as the smallest element in the
beginning, and not in any of the methods' docs. There's no method to access the
minimal element without popping it, and the documentation of nsmallest is
confusing because it may suggest that min() is the way to go for n==1.
Doc/library/heapq.rst