Split - Maple Help

# Online Help

###### All Products    Maple    MapleSim

MmaTranslator[Mma]

 Split
 split a list into sublists

 Calling Sequence Split(arguments)

Parameters

 arguments - Maple translation of the Mathematica command arguments

Description

 • The Split command splits a list into sublists containing runs of identical items.

Examples

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

Use the command with the Maple translation.

 > $\mathrm{Split}\left(\left[a,a,b,c,d,e,f,f,g,h,i\right]\right)$
 $\left[\left[{a}{,}{a}\right]{,}\left[{b}\right]{,}\left[{c}\right]{,}\left[{d}\right]{,}\left[{e}\right]{,}\left[{f}{,}{f}\right]{,}\left[{g}\right]{,}\left[{h}\right]{,}\left[{i}\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{Split\left[\left\{a, a, b, c, d, e, f, f, g, h, i\right\}\right]},\mathrm{evaluate}\right)$
 $\left[\left[{a}{,}{a}\right]{,}\left[{b}\right]{,}\left[{c}\right]{,}\left[{d}\right]{,}\left[{e}\right]{,}\left[{f}{,}{f}\right]{,}\left[{g}\right]{,}\left[{h}\right]{,}\left[{i}\right]\right]$ (2)

 See Also