Navigation
Synopsis Split a list into two halves.
Function tuple[list[&T],list[&T]] split(list[&T] l)
Usage import List;
Examples
rascal>import List;
ok
rascal>split([3, 1, 4, 5, 7]);
tuple[list[int],list[int]]: <[3,1],[4,5,7]>
rascal>split(["zebra", "elephant", "snake", "owl"]);
tuple[list[str],list[str]]: <["zebra","elephant"],["snake","owl"]>

Questions
Question [1].
The type of split(["Grape", "E", "Forgetful Jones", "Count Von Count", "Darth Sidious"]) is

Question [2].
split(["I", "Prince Charming", "D", "M", "Prince Charming"]) == 



Is this page unclear, or have you spotted an error? Please add a comment below and help us to improve it. For all other questions and remarks, visit ask.rascal-mpl.org.