Get the value at the nth place of a list without converting the list to an
array; returns Nothing if the list contains fewer than n + 1 items, or if
n is negative
getNth 0 [1, 3, 9, 27] --> Just 1
getNth 3 [1, 3, 9, 27] --> Just 27
getNth 4 [1, 3, 9, 27] --> Nothing
getNth -1 [1, 3, 9, 27] --> NothingGiven a list of values, returns the unique values as a list sorted from highest to lowest
Returns the first two items in a list as a 2-tuple, or Nothing if the list
contains fewer than two items
take2Tuple [1,2] --> Just (1,2)
take2Tuple [1,2,3] --> Just (1,2)
take2Tuple [1] --> NothingReturns the first three items in a list as a 3-tuple, or Nothing if the
list contains fewer than three items
Returns the first four items in a list as a 4-tuple, or Nothing if the
list contains fewer than four items
Given a 2-tuple where both values are of the same type, return a list containing those values
Given a 3-tuple where all three values are of the same type, return a list containing those values
Given a 4-tuple where all four values are of the same type, return a list containing those values
Convert a 2-tuple of lists to a list of 2-tuples
zip ([0,17,1337], [True,False,True])
--> [(0, True), (17, False), (1337, True)]Convert a 3-tuple of lists to a list of 3-tuples
Convert a 4-tuple of lists to a list of 4-tuples
Convert a 3-tuple of lists to a list of 3-tuples (see List.unzip)
Convert a 4-tuple of lists to a list of 4-tuples
Given a list and a test value, returns
Trueif the list contains a value equal to the test value.Equivalent to List.member with the arguments flipped