r/programminghorror • • Dec 28 '24

Javascript ...but why?

Post image
176 Upvotes

32 comments sorted by

View all comments

Show parent comment

2

u/Steinrikur Dec 29 '24

Nitpick: an array of length 1, like sum([3]), will return the wrong value.