tail()¶
-
FunctionalX.src.lists._tail.
tail
(list1: list) → list¶ Return the tail of a list
Return the rest of the list (beyond the first element). If the input list is empty or has only one element, then return [].
Parameters: list1 (list) – input list Returns: a new list Return type: list >>> tail([]) []
>>> tail([1]) []
>>> tail([1,2,3]) [2,3]