mirror of
https://github.com/python/cpython.git
synced 2025-07-30 06:34:15 +00:00
I believe the intention here was to avoid a global lookup
This commit is contained in:
parent
4829136965
commit
fb921e2c00
1 changed files with 1 additions and 1 deletions
|
@ -195,7 +195,7 @@ def nlargest(n, iterable):
|
|||
heapify(result)
|
||||
_heappushpop = heappushpop
|
||||
for elem in it:
|
||||
heappushpop(result, elem)
|
||||
_heappushpop(result, elem)
|
||||
result.sort(reverse=True)
|
||||
return result
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue