śĪ!AłĄ      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ”¢£¤„¦§Ø©Ŗ«¬­®Æ°±²³“µ¶·ø¹ŗ»¼½¾æSafe ©Ąfoldl A strict ĮĀfoldl A strict ĆÄfoldlConvert Ā to ĆÅfoldlConvert Ć to ĀĘfoldlConvert Ą to Ć ĒČĄÉŹĀĖĢÄÅĘSafeSX ĶĪĻŠŃ Trustworthy>ESX¬QTfoldl$A Handler for the upstream input of  3Any lens, traversal, or prism will type-check as a  foldl xinstance Monad m => Monoid (EndoM m a) where mempty = EndoM return mappend (EndoM f) (EndoM g) = EndoM (f <=< g) foldl&A handler for the upstream input of a 3Any lens, traversal, or prism will type-check as a  foldlLike , but monadic.A ' # m a b' processes elements of type a, and results in a monadic value of type m b.foldlFoldM   step   initial   extractfoldlEfficient representation of a left fold that preserves the fold's step function, initial accumulator, and extraction functionThis allows the ŅM instance to assemble derived folds that traverse the container only onceA '! a b' processes elements of type a$ and results in a value of type b.foldlFold   step   initial   extractfoldlApply a strict left  to a  containerfoldlLike  , but monadicfoldlConvert a strict left  into a scanL.scan L.length [1..5] [0,1,2,3,4,5]foldl Convert a  into a prescan for any Ó typeA"Prescan" means that the last element of the scan is not includedL.prescan L.length [1..5] [0,1,2,3,4]foldl Convert a  into a postscan for any Ó typeC"Postscan" means that the first element of the scan is not includedL.postscan L.length [1..5] [1,2,3,4,5]foldl)Fold all values within a container using Ō and Õfoldl Convert a "foldMap" to a foldl/Get the first element of a container or return Ö if the container is emptyfoldl.Get the last element of a container or return Ö if the container is emptyfoldl[Get the last element of a container or return a default value if the container is emptyfoldlReturn the last N elementsfoldlReturns × if the container is empty, Ų otherwisefoldl"Return the length of the containerfoldlReturns × if all elements are ×, Ų otherwisefoldlReturns × if any element is ×, Ų otherwise foldl(all predicate) returns ×, if all elements satisfy the predicate, Ų otherwise!foldl(any predicate) returns ×- if any element satisfies the predicate, Ų otherwise"foldl Computes the sum of all elements#foldl$Computes the product of all elements$foldl<Compute a numerically stable arithmetic mean of all elements%foldlDCompute a numerically stable (population) variance over all elements&foldlRCompute a numerically stable (population) standard deviation over all elements'foldlComputes the maximum element(foldlNComputes the maximum element with respect to the given comparison function)foldlComputes the minimum element*foldlNComputes the minimum element with respect to the given comparison function+foldl(elem a) returns ×* if the container has an element equal to a, Ų otherwise,foldl (notElem a) returns Ų* if the container has an element equal to a, × otherwise-foldl(find predicate)? returns the first element that satisfies the predicate or Ö& if no element satisfies the predicate.foldl (index n) returns the n th element of the container, or Ö< if the container has an insufficient number of elements/foldl (elemIndex a)4 returns the index of the first element that equals a , or Ö if no element matches0foldl(findIndex predicate)M returns the index of the first element that satisfies the predicate, or Ö& if no element satisfies the predicate1foldl (lookup a)A returns the element paired with the first matching item, or Ö if none matches2foldl/Pick a random element, using reservoir sampling3foldl6Pick several random elements, using reservoir sampling4foldlAConverts an effectful function to a fold. Specialized version of 5.5foldl(Converts an effectful function to a fold Qsink (f <> g) = sink f <> sink g -- if `(<>)` is commutative sink mempty = mempty6foldlLike , except with a more general Ł return value7foldlLike ., except with a more general Ś argument8foldlFold all values into a list9foldl-Fold all values into a list, in reverse order:foldl O(n log n)`. Fold values into a list with duplicates removed, while preserving their first occurrences;foldlO(n^2)`. Fold values into a list with duplicates removed, while preserving their first occurrences<foldlFold values into a set=foldlFold values into a hash-set>foldlFold pairs into a map.?foldlGiven a  , produces a Ū! which applies that fold to each a separated by key k.Lfold (foldByKeyMap Control.Foldl.sum) [("a",1), ("b",2), ("b",20), ("a",10)]fromList [("a",11),("b",22)]@foldlFold pairs into a hash-map.AfoldlGiven a  , produces a Ü! which applies that fold to each a separated by key k.Pfold (foldByKeyHashMap Control.Foldl.sum) [("a",1), ("b",2), ("b",20), ("a",10)]fromList [("a",11),("b",22)]BfoldlFold all values into a vectorCfoldlFold all values into a vectorThis is more efficient than B but is impureDfoldlUpgrade a fold to accept the  typeEfoldl.Upgrade a more traditional fold to accept the  typeFfoldl%Upgrade a monadic fold to accept the   typeGfoldl6Upgrade a more traditional monadic fold to accept the   typeHfoldl Generalize a  to a  Rgeneralize (pure r) = pure r generalize (f <*> x) = generalize f <*> generalize xIfoldlSimplify a pure   to a  Jsimplify (pure r) = pure r simplify (f <*> x) = simplify f <*> simplify xJfoldlShift a  3 from one monad to another with a morphism such as lift or liftIO!; the effect is the same as .KfoldlAllows to continue feeding a  4 even after passing it to a function that closes it. For pure s, this is provided by the Ż instance.Lfoldl _Fold1 step returns a new ‹ using just a step function that has the same type for the accumulator and the element. The result type is the accumulator type wrapped in Ć0. The initial accumulator is retrieved from the , the result is None for empty containers.Mfoldl(premap f folder) returns a new  where f is applied at each step ;fold (premap f folder) list = fold folder (List.map f list)#fold (premap Sum L.mconcat) [1..10]Sum {getSum = 55}%fold L.mconcat (List.map Sum [1..10])Sum {getSum = 55} 4premap id = id premap (f . g) = premap g . premap f Jpremap k (pure r) = pure r premap k (f <*> x) = premap k f <*> premap k xNfoldl(premapM f folder) returns a new  - where f is applied to each input element <premapM return = id premapM (f <=< g) = premap g . premap f NpremapM k (pure r) = pure r premapM k (f <*> x) = premapM k f <*> premapM k xOfoldl(prefilter f folder) returns a new O where the folder's input is used only when the input satisfies a predicate fThis can also be done with T (handles (filtered f)) but  prefilter1 does not need you to depend on a lens library. <fold (prefilter p folder) list = fold folder (filter p list)/fold (prefilter (>5) Control.Foldl.sum) [1..10]40,fold Control.Foldl.sum (filter (>5) [1..10])40Pfoldl(prefilterM f folder) returns a new  X where the folder's input is used only when the input satisfies a monadic predicate f. ?foldM (prefilterM p folder) list = foldM folder (filter p list)Qfoldl Transforms a K into one which ignores elements until they stop satisfying a predicate Bfold (predropWhile p folder) list = fold folder (dropWhile p list)5fold (predropWhile (>5) Control.Foldl.sum) [10,9,5,9]14Rfoldl(drop n folder) returns a new  that ignores the first n< inputs but otherwise behaves the same as the original fold. Ffold (drop n folder) list = fold folder (Data.List.genericDrop n list)-L.fold (L.drop 3 L.sum) [10, 20, 30, 1, 2, 3]6.L.fold (L.drop 10 L.sum) [10, 20, 30, 1, 2, 3]0Sfoldl(dropM n folder) returns a new   that ignores the first n< inputs but otherwise behaves the same as the original fold. IfoldM (dropM n folder) list = foldM folder (Data.List.genericDrop n list)>L.foldM (L.dropM 3 (L.generalize L.sum)) [10, 20, 30, 1, 2, 3]6?L.foldM (L.dropM 10 (L.generalize L.sum)) [10, 20, 30, 1, 2, 3]0Tfoldl(handles t folder) transforms the input of a ' using a lens, traversal, or prism: Żhandles _1 :: Fold a r -> Fold (a, b) r handles _Left :: Fold a r -> Fold (Either a b) r handles traverse :: Traversable t => Fold a r -> Fold (t a) r handles folded :: Foldable t => Fold a r -> Fold (t a) r,fold (handles traverse sum) [[1..5],[6..10]]55^fold (handles (traverse.traverse) sum) [[Nothing, Just 2, Just 7],[Just 13, Nothing, Just 20]]42*fold (handles (filtered even) sum) [1..10]30>fold (handles _2 L.mconcat) [(1,"Hello "),(2,"World"),(3,"!")]"Hello World!" 8handles id = id handles (f . g) = handles f . handles g Nhandles t (pure r) = pure r handles t (f <*> x) = handles t f <*> handles t xUfoldl(foldOver f folder xs)M folds all values from a Lens, Traversal, Prism or Fold with the given folder+foldOver (_Just . both) L.sum (Just (2, 3))5%foldOver (_Just . both) L.sum Nothing0 0L.foldOver f folder xs == L.fold folder (xs^..f) 9L.foldOver (folded.f) folder == L.fold (handles f folder) L.foldOver folded == L.foldVfoldl(handlesM t folder) transforms the input of a  ' using a lens, traversal, or prism: õhandlesM _1 :: FoldM m a r -> FoldM (a, b) r handlesM _Left :: FoldM m a r -> FoldM (Either a b) r handlesM traverse :: Traversable t => FoldM m a r -> FoldM m (t a) r handlesM folded :: Foldable t => FoldM m a r -> FoldM m (t a) rV obeys these laws: <handlesM id = id handlesM (f . g) = handlesM f . handlesM g RhandlesM t (pure r) = pure r handlesM t (f <*> x) = handlesM t f <*> handlesM t xWfoldl(foldOverM f folder xs)Y folds all values from a Lens, Traversal, Prism or Fold monadically with the given folder <L.foldOverM (folded.f) folder == L.foldM (handlesM f folder) L.foldOverM folded == L.foldMXfoldl ^folded :: Foldable t => Fold (t a) a handles folded :: Foldable t => Fold a r -> Fold (t a) rYfoldl*fold (handles (filtered even) sum) [1..10]308foldM (handlesM (filtered even) (L.mapM_ print)) [1..10]246810Zfoldl Perform a ‹ while grouping the data according to a specified group projection function. Returns the folded result grouped as a map keyed by the group.[foldl=Combine two folds into a fold over inputs for either of them.\foldlECombine two monadic folds into a fold over inputs for either of them.]foldlNest a fold in an applicative.[  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\][  !"#$%&'()*+,-.1/023456789:;<=>?@ABCDEFGHIJKLMNOPQRS TU VWXYZ[\]NoneŗsfoldlApply a strict left  to a lazy bytestringtfoldlApply a strict monadic left   to a lazy bytestringufoldl.Get the first byte of a byte stream or return Ö if the stream is emptyvfoldl-Get the last byte of a byte stream or return Ö if the byte stream is emptywfoldlReturns × if the byte stream is empty, Ų otherwisexfoldl-Return the length of the byte stream in bytesyfoldl(all predicate) returns ×% if all bytes satisfy the predicate, Ų otherwisezfoldl(any predicate) returns ×* if any byte satisfies the predicate, Ų otherwise{foldlComputes the maximum byte|foldlComputes the minimum byte}foldl (elem w8) returns ×( if the byte stream has a byte equal to w8, Ų otherwise~foldl (notElem w8) returns Ų( if the byte stream has a byte equal to w8, × otherwisefoldl(find predicate)< returns the first byte that satisfies the predicate or Ö# if no byte satisfies the predicate€foldl (index n) returns the nth byte of the byte stream, or Ö6 if the stream has an insufficient number of bytesfoldl(elemIndex w8)1 returns the index of the first byte that equals w8 , or Ö if no byte matches‚foldl(findIndex predicate)J returns the index of the first byte that satisfies the predicate, or Ö# if no byte satisfies the predicateƒfoldlcount w8 returns the number of times w8 appears„foldlCombine all the strict  chunks to build a lazy  stuvwxyz{|}~€‚ƒ„stuvwxzy{|}~€‚ƒ„ SafeŻÉ…foldlApply a strict left  to lazy text†foldlApply a strict monadic left   to lazy text‡foldl3Get the first character of a text stream or return Ö if the stream is emptyˆfoldl2Get the last character of a text stream or return Ö if the text stream is empty‰foldlReturns × if the text stream is empty, Ų otherwiseŠfoldl2Return the length of the text stream in characters‹foldl(all predicate) returns ×. if all characters satisfy the predicate, Ų otherwiseŒfoldl(any predicate) returns ×/ if any character satisfies the predicate, Ų otherwisefoldlComputes the maximum characterŽfoldlComputes the minimum characterfoldl(elem c) returns ×- if the text stream has a character equal to c, Ų otherwisefoldl (notElem c) returns Ų1 if the text stream has a character equal to c, × otherwise‘foldl(find predicate)A returns the first character that satisfies the predicate or Ö( if no character satisfies the predicate’foldl (index n) returns the n$th character of the text stream, or Ö; if the stream has an insufficient number of characters“foldl (elemIndex c)6 returns the index of the first character that equals c , or Ö if no character matches”foldl(findIndex predicate)O returns the index of the first character that satisfies the predicate, or Ö, if no character satisfies the predicate•foldl (count c) returns the number of times c appears–foldlCombine all the strict  chunks to build a lazy  …†‡ˆ‰Š‹ŒŽ‘’“”•–…†‡ˆ‰ŠŒ‹Ž‘’“”•– None>EPSXJ—foldlLike ™, but monadic.A '—# m a b' processes elements of type a, and results in a monadic value of type m b.˜foldlScanM   step   initial   extract™foldl|Efficient representation of a left map-with-accumulator that preserves the scan's step function and initial accumulator.This allows the ŅM instance to assemble derived scans that traverse the container only onceA '™! a b' processes elements of type a) replacing each with a value of type b.šfoldlScan   step   initial ›foldlApply a strict left ™ to a Ó containerœfoldlLike ›" but start scanning from the rightfoldlLike › but monadicžfoldl Convert a  into a prescanA"Prescan" means that the last element of the scan is not includedŸfoldl Convert a  into a postscanC"Postscan" means that the first element of the scan is not included”foldlUpgrade a scan to accept the ™ type¢foldl.Upgrade a more traditional scan to accept the ™ type£foldl%Upgrade a monadic scan to accept the — type¤foldl6Upgrade a more traditional monadic scan to accept the — type„foldl Generalize a ™ to a — Rgeneralize (pure r) = pure r generalize (f <*> x) = generalize f <*> generalize x¦foldlSimplify a pure — to a ™ Jsimplify (pure r) = pure r simplify (f <*> x) = simplify f <*> simplify x§foldlShift a —3 from one monad to another with a morphism such as Ž or liftIO!; the effect is the same as .Øfoldl(premap f scaner) returns a new ™ where f is applied at each step 6scan (premap f scaner) list = scan scaner (map f list) 4premap id = id premap (f . g) = premap g . premap f Jpremap k (pure r) = pure r premap k (f <*> x) = premap k f <*> premap k x©foldl(premapM f scaner) returns a new —- where f is applied to each input element <premapM return = id premapM (f <=< g) = premap g . premap f NpremapM k (pure r) = pure r premapM k (f <*> x) = premapM k f <*> premapM k xßfoldllThis is same as normal function composition, except slightly more efficient. The same trick is used in base  Vhttp://hackage.haskell.org/package/base-4.11.1.0/docs/src/Data.Functor.Utils.html#%23. and lens \http://hackage.haskell.org/package/lens-4.17/docs/Control-Lens-Internal-Coerce.html#v:-35-..—˜™š›œžŸ ”¢£¤„¦§Ø©™š—˜›œžŸ”¢£¤„¦§ Ø©ß9 ą    !""##$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ„…$%+,/034:<>?@ABC†‡$%+,/034:<>?@ABC†‡ˆˆ‰‰&Š‹'(ŒWXYZ[\]`aŽ‘’“”•–—˜™š›œžŸ ”¢£ ¤„¦ §Ø‡©Ŗ««¬­®Æ°±²³“ µ¶ ·ø µ¹ µŗ §» ¼½ ¼¾ æĄ ĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠ!foldl-1.4.7-ErFfaUvWiJDJJnVNVMiyg Control.FoldlControl.Foldl.ByteStringControl.Foldl.Text Control.ScanlControl.Foldl.InternalControl.Foldl.OpticsControl.Monad.Morphhoistbase Data.FoldableFoldableghc-primGHC.Prim RealWorldGHC.WordWord8bytestring-0.10.8.2Data.ByteString.Internal ByteString'primitive-0.7.0.1-4OYEE8uw8FE1Ko7THF1ebControl.Monad.Primitive PrimMonad text-1.2.3.1Data.Text.InternalText&vector-0.12.1.2-E9YBdJZ4ywF23gc9L8wAxpData.Vector.Generic.BaseMutableVectorHandlerMEndoMappEndoMHandlerFoldMFoldfoldfoldMscanprescanpostscanmconcatfoldMapheadlastlastDeflastNnulllengthandorallanysumproductmeanvariancestdmaximum maximumByminimum minimumByelemnotElemfindindex elemIndex findIndexlookuprandomrandomNmapM_sink genericLength genericIndexlistrevListnubeqNubsethashSetmap foldByKeyMaphashMapfoldByKeyHashMapvectorvectorMpurelypurely_impurely impurely_ generalizesimplifyhoists duplicateM_Fold1premappremapM prefilter prefilterM predropWhiledropdropMhandlesfoldOverhandlesM foldOverMfoldedfilteredgroupByeithereitherMnest$fFloatingFold$fFractionalFold $fNumFold $fMonoidFold$fSemigroupoidTYPEFold$fSemigroupFold$fApplicativeFold $fComonadFold $fChoiceFold$fProfunctorFold $fFunctorFold$fFloatingFoldM$fFractionalFoldM $fNumFoldM $fMonoidFoldM$fSemigroupFoldM$fProfunctorFoldM$fApplicativeFoldM$fFunctorFoldM $fMonoidEndoM$fSemigroupEndoMcountlazyScanMScanscanrscanMarrM$fFloatingScan$fFractionalScan $fNumScan $fMonoidScan$fSemigroupScan $fArrowScan$fCategoryTYPEScan$fProfunctorScan$fApplicativeScan $fFunctorScan$fFloatingScanM$fFractionalScanM $fNumScanM $fMonoidScanM$fSemigroupScanM $fArrowScanM$fCategoryTYPEScanM$fProfunctorScanM$fApplicativeScanM$fFunctorScanM$fApplicativeReverseState$fFunctorReverseStateEither' Data.EitherEitherMaybe' GHC.MaybeMaybestricthushPairLeft'Right'Just'Nothing'Prism'Prismprism_Left_RightGHC.Base ApplicativeData.Traversable TraversablemappendmemptyNothing GHC.TypesTrueFalseGHC.NumNumGHC.RealIntegralcontainers-0.6.0.1Data.Map.InternalMap4unordered-containers-0.2.11.0-1MOVU81zMqZ99QGh31OSN0Data.HashMap.BaseHashMap$comonad-5.0.6-JfcN6iPhxp7Eeulcp61Z8tControl.ComonadComonadtransformers-0.5.5.0Control.Monad.Trans.Classlift#.