3 ms·
curious how often reduce is used with something else than operator.add?
by baq 10y ago
curious how often reduce is used with something else than operator.add?
- S4M 10y agoOne occurence was to calculate the GCD of a list of polynomials. In fact I had "reduce" appearing in the names of some of my variables so I used it less than 32 times, about 20 times in that project.
- d0mine 10y agoI see nothing particularly inspiring in the examples posted on http://stackoverflow.com/questions/15995/useful-code-which-uses-reduce-in-python http://stackoverflow.com/questions/15995/useful-code-which-u... Could you show your reduce calls?
- S4M 10y agoThey are very similar to this one from your link: http://stackoverflow.com/questions/15995/useful-code-which-uses-reduce-in-python/282206#282206 http://stackoverflow.com/questions/15995/useful-code-which-u...