Python reduce function

Share

This is an interesting short cut function when you want to process list items recursively. This function takes two arguments in as input, one function name that you want to apply on list and second the list itself. In python3 reduce is available in func_tools module. Typical syntax to invoke this is reduce(function_name, list_of_items) and […]