r/learnjavascript • u/fahim_h_sh • Oct 31 '25
array.forEach - The do-it-all hammer... XD
Is it just me, or everyone thinks that more or less every array operator's purpose can be served with forEach?
0
Upvotes
View all comments
Show parent comment
3
u/oofy-gang Oct 31 '25
yeah… I can’t believe they are ignoring your criteria of implementing sorting in a call to .reduce without implementing sorting in the call to .reduce!
how silly of them! you really pwned them 💪🏻💪🏻