Skip to content
Create a gist now

Instantly share code, notes, and snippets.

import Data.Conduit
import Data.Conduit.List (drop, isolate, fold)
import Prelude hiding (drop)
main :: IO ()
main = do
res <- mapM_ yield [1..20] $$ do
drop 5
res1 <- isolate 5 =$ fold (+) 0
drop 5
res2 <- isolate 5 =$ fold (+) 0
return (res1, res2)
print res
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.