Stream merge: Difference between revisions
Regularize non-standard header markup
Thundergnat (talk | contribs) m (Thundergnat moved page Stream Merge to Stream merge: Follow normal task title capitalization policy) |
Thundergnat (talk | contribs) (Regularize non-standard header markup) |
||
Line 1,189:
</pre>
==
There is no built-in iterator or stream type for file operations in Haskell. But several such libraries exist.
Line 1,714:
sockets).
==
Built-in function <code>open</code> opens a file for reading and returns a line-by-line iterator (stream) over the file.
Line 1,815:
monkey</pre>
==
===version 1===
<lang rexx>/* REXX ***************************************************************
Line 2,133:
</lang>
==
sort --merge source1 source2 sourceN > sink
==
This solution uses iterators, doesn't care where the streams orginate and only keeps the head of the stream on hand.
<lang zkl>fcn mergeStreams(s1,s2,etc){ //-->Walker
|