loading...

Dynamic Reducer - Python

hvaandres profile image Andres Haro ・1 min read

The reducer is a pure function that takes the current state and an action and returns the next state. Note that the state is accumulated as each action on the collection is applied to change this state. So given a collection of actions, the reducer is applied to each value of the collection (from left-to-right).

At this point, this is an example of how to do a dynamic reducer by using the following libraries "operator & reduce."

Discussion

markdown guide