[New-bugs-announce] [issue40239] Add a function for merging sorted iterables
Serhiy Storchaka
report at bugs.python.org
Thu Apr 9 10:42:29 EDT 2020
New submission from Serhiy Storchaka <storchaka+cpython at gmail.com>:
It would be useful to have a function in itertools to merge sorted iterables.
merge_sorted(*iterables, key=None, reverse=False):
It should emit the same items as sorted(tee(*iterables), key=key, reverse=reverse) if iterables are sorted with key and reverse. But it should use the amount of memory O(M) where M is the number of iterables, and support infinite iterables.
----------
components: Library (Lib)
messages: 366056
nosy: rhettinger, serhiy.storchaka, tim.peters
priority: normal
severity: normal
status: open
title: Add a function for merging sorted iterables
type: enhancement
versions: Python 3.9
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue40239>
_______________________________________
More information about the New-bugs-announce
mailing list