
Hello, From Hoogle (my friend) .... *intercalate* :: ByteStringhttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/Data...-> [ ByteStringhttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/Data...] -> ByteStringhttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/Data... Sourcehttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/src/... *O(n)* The intercalatehttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/Data...function takes a ByteStringhttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/Data...and a list of ByteStringhttp://hackage.haskell.org/packages/archive/bytestring/0.9.1.4/doc/html/Data...s and concatenates the list after interspersing the first argument between each element of the list. So intercalate doesn't do a simple concatenation? Vasili

vigalchin:
Hello,
From Hoogle (my friend) ....
intercalate :: [1]ByteString -> [[2]ByteString] -> [3]ByteString [4]Source O(n) The [5]intercalate function takes a [6]ByteString and a list of [7]ByteStrings and concatenates the list after interspersing the first argument between each element of the list. So intercalate doesn't do a simple concatenation?
FWIW. concat . intersperse x == intercalate x -- Don
participants (2)
-
Don Stewart
-
Galchin, Vasili