dropLastInPlace

Returns a sublist containing all elements except last n elements. The sublist is a view into the original list. Changes in the original list will be reflected in the sublist.

Return

A list containing all elements except last n elements.

Parameters

n

The number of elements to drop from the end.