DEV Community

Discussion on: What s wrong with Array.reduce ?

Collapse
 
patarapolw profile image
Pacharapol Withayasakpunt • Edited

I almost always to write first argument as prev or acc; therefore,

numbers.reduce((prev, current) => current > prev ? current : prev)

About readability, I guess it depends on how you visualize.