array_pick_best_element
array_pick_best_element(array, scoreFunction) ⇒ T
| undefined
Picks element with highest score from the array using supplied scoring function. If multiple elements with the same highest score exist, the result will be first such encountered element
Kind: global function
Param | Type |
---|---|
array | Array.<T> |
scoreFunction | function |