The list-grouping package

[Tags: bsd3, deprecated, library]

Deprecated in favor of split

Functions for grouping a list into sublists based on predicate or integer offsets.

NOTE: THIS MODULE IS DEPRECATED. PLEASE TRY THE split PACKAGE INSTEAD http:hackage.haskell.orgpackagesplit-0.1.3

Grouping a list based on integer offsets:

 splitEvery 3 [1..10]  ==  [[1,2,3],[4,5,6],[7,8,9],[10]]
 splitWith [1,3,1,3] [1..10]  ==  [[1],[2,3,4],[5],[6,7,8],[9,10]]
 splitWithDrop [1,3,1,3] [1..10]  ==  [[1],[2,3,4],[5],[6,7,8]]

Grouping based on a predicate:

 breakBefore odd [2..9]  ==  [[2],[3,4],[5,6],[7,8],[9]]
 breakAfter odd [2..9]  ==  [[2,3],[4,5],[6,7],[8,9]]
 breakDrop odd [0,0,0,1,0,1,1,0,0]  ==  [[0,0,0],[0],[0,0]]

Please send me any comments, requests or bug reports

Properties

Versions0.1, 0.1.1
Change logNone available
Dependenciesbase (<5) [details]
LicenseBSD3
Copyright(c) 2009, Brandon Simmons <brandon.m.simmons@gmail.com>
AuthorBrandon Simmons
MaintainerBrandon Simmons <brandon.m.simmons@gmail.com>
CategoryData
Home pagehttp://coder.bsimmons.name/blog/2009/08/list-grouping-module-released/
UploadedSun Feb 13 19:23:41 UTC 2011 by BrandonSimmons
DistributionsNixOS:0.1.1
Downloads391 total (19 in last 30 days)
Votes
0 []
StatusDocs uploaded by user
Build status unknown [no reports yet]

Modules

[Index]

Downloads

Maintainers' corner

For package maintainers and hackage trustees