Partition - Maple Help

MmaTranslator[Mma]

 Partition
 return a list of non-overlapping lists

 Calling Sequence Partition(arguments)

Parameters

 arguments - Maple translation of the Mathematica command arguments

Description

 • The Partition command returns a list of non-overlapping sublists of a specified length.

Examples

 > $\mathrm{with}\left({\mathrm{MmaTranslator}}_{\mathrm{Mma}}\right):$

Use the command with the Maple translation.

 > $\mathrm{Partition}\left(\left[a,b,c,d,e,f,g,h\right],2\right)$
 $\left[\left[{a}{,}{b}\right]{,}\left[{c}{,}{d}\right]{,}\left[{e}{,}{f}\right]{,}\left[{g}{,}{h}\right]\right]$ (1)

Alternatively, you can use the FromMma command with the evaluate option specified.

 > $\mathrm{with}\left(\mathrm{MmaTranslator}\right):$
 > $\mathrm{FromMma}\left(\mathrm{Partition\left[\left\{a, b, c, d, e, f, g, h\right\}, 2\right]},\mathrm{evaluate}\right)$
 $\left[\left[{a}{,}{b}\right]{,}\left[{c}{,}{d}\right]{,}\left[{e}{,}{f}\right]{,}\left[{g}{,}{h}\right]\right]$ (2)