reverseList
lib.lists.reverseList
Docs pulled from | This Revision | 10 minutes ago
Reverse the order of the elements of a list.
Inputs
xs
-
1. Function argument
Type
reverseList :: [a] -> [a]
Examples
lib.lists.reverseList
usage example
reverseList [ "b" "o" "j" ]
=> [ "j" "o" "b" ]
Noogle detected
Implementation
The following is the current implementation of this function.
reverseList = xs:
let l = length xs; in genList (n: elemAt xs (l - n - 1)) l;