[ library(lists) | Reference Manual | Alphabetic Index ]

halve(+List, ?Front, ?Back)

Split a list in the middle


Returns two lists (Front and Back) which can be concatenated to give the original List. The length of the sub-lists is half the length of the original. If the original length is odd, Front is one longer

Modes and Determinism


	halve([a,b,c,d,e,f], [a,b,c], [d,e,f])
	halve([a,b,c,d,e,f,g], [a,b,c,d], [e,f,g])

See Also

append / 3