Ds\Map::reduce

Ds\Map::reduce

(PECL ds >= 1.0.0)

Ds\Map::reduceReduces the map to a single value using a callback function.

Description

public mixed Ds\Map::reduce ( callable $callback [, mixed $initial ] )

Reduces the map to a single value using a callback function.

Parameters

callback
mixed callback ( mixed $carry , mixed $key , mixed $value )
carry

登录查看完整内容