NAME
Array::Split - split an array into sub-arrays
VERSION
version 1.103261
SYNOPSIS
use Array::Split qw( split_by split_into );
DESCRIPTION
This module offers functions to separate all the elements of one array into multiple arrays.
split_by ( $split_size, @original )
Splits up the original array into sub-arrays containing the contents of the original. Each sub-array's size is the same or less than $split_size, with the last one usually being the one to have less if there are not enough elements in @original.
split_into ( $count, @original )
Splits the given array into even-sized (as even as maths allow) sub-arrays. It tries to create as many sub-arrays as $count indicates, but will return less if there are not enough elements in @original.
Returns a list of array references.
AUTHOR
Christian Walde <mithaldu@yahoo.de>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2010 by Christian Walde.
This is free software, licensed under:
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE, Version 2, December 2004