Difference between revisions of "Array.chunks()"
Jump to navigation
Jump to search
Line 29: | Line 29: | ||
| 25 | | 25 | ||
|} | |} | ||
+ | |||
+ | |||
+ | == See Also == | ||
+ | [[Array.pieces()| pieces]] | ||
+ | |||
+ | [[Array.parts()| parts]] |
Latest revision as of 20:53, 21 March 2024
Array.chunks(ChunkSize, SomeFunction)
Split the array into chunks of size ChunkSize. Apply SomeFunction to chunks, if provided.
1..25.chunks(3)
1 | 2 | 3 |
4 | 5 | 6 |
7 | 8 | 9 |
10 | 11 | 12 |
13 | 14 | 15 |
16 | 17 | 18 |
19 | 20 | 21 |
22 | 23 | 24 |
25 |