_.cond(pairs)
Creates a function that iterates over pairs and invokes the corresponding function of the first predicate to return truthy. The predicate-function pairs are invoked with the this binding and arguments of the created function.
Arguments
pairs (Array)
: The predicate-function pairs.
Returns
(Function)
: Returns the new composite function.