I do not understand last_ ...

31 views
Skip to first unread message

Massimiliano Gubinelli

unread,
Jan 28, 2018, 12:31:11 PM1/28/18
to Haskell Pipes
Hi all,
 I'm a bit puzzled by the following output:

Prelude> import qualified Streaming.Prelude as S
Prelude S> S.last $ S.each [1..100]
Just 100 :> ()
Prelude S> S.last $ (S.slidingWindow 10) $ S.each [1..100]
Nothing :> ()

Why in the second case I obtain a Nothing?
And what is a natural way to output the structure of a Stream  ?

Thanks a lot!
Max

Reply all
Reply to author
Forward
0 new messages