(a -> b -> c) -> (a, b) -> c
uncurry converts a curried function to a function on pairs.
O(n). Build a map from a list of key/value pairs are in ascending order, with a combining function on equal keys. The precondition (input list is ascending) is not checked.
> fromAscListWith (++) [(3,"b"), (5,"a"), (5,"b")] == fromList [(3, "b"), (5, "ba")]
O(n*min(n,W)). Create a map from a list of key/value pairs with a combining function. See also fromAscListWith.
> fromListWith (++) [(5,"a"), (5,"b"), (3,"b"), (3,"a"), (5,"a")] == fromList [(3, "ab"), (5, "aba")]
> fromListWith (++) [] == empty
O(n*min(n,W)). Create a map from a list of key/value pairs with a combining function. See also fromAscListWith.
> fromListWith (++) [(5,"a"), (5,"b"), (3,"b"), (3,"a"), (5,"c")] == fromList [(3, "ab"), (5, "cba")]
> fromListWith (++) [] == empty