News for hackers. Stuff that matters.
Re:Programmers can’t write algorithms without help by Tehchops on Monday November 04, 2019 @11:21AM (#21443029)
Purely anecdotally: I've seen online discourse that suggests that the complex nature of the modern web requires FE devs be able to keep at least a couple efficient data-structure traversal tools in their toolbox.

Anyone with more experience could probably chime in.

Re:Programmers can’t write algorithms without help by starbugs on Monday November 04, 2019 @11:25AM (#21443106)
Yes, being able to write a DFS is definitely a good thing. For more complex stuff I don't mind if you need to look it up.
Re:Programmers can’t write algorithms without help by rhinoceraptor on Monday November 04, 2019 @01:43PM (#21444877)
In my experience, most front end performance problems are just unoptimized assets, or huge JS bundles. After that, there's issues where you're doing a lot of unnecessary rendering, for example in a React app, a Redux mapStateToProps function that isn't memoizing an array map, which is causing the whole subtree to re-render on every state update. The only time I even needed algorithmic complexity was implementing a drag and drop control, for a list that could have several hundred thousand elements, and my naive implementation was n^2.
Re:Programmers can’t write algorithms without help by jimbokun on Monday November 04, 2019 @02:30PM (#21445434)
> that isn't memoizing an array map

"memoizing" is a pretty computer-sciencey word, so not implementing a data structure exactly, but still requires knowledge beyond "plug these APIs together."

> The only time I even needed algorithmic complexity was implementing a drag and drop control, for a list that could have several hundred thousand elements, and my naive implementation was n^2.

And if you didn't have an intuition for algorithmic complexity, how long would it have taken you to figure out the problem? And how many times have you instinctively avoided having an explosion in algorithmic complexity, by intuitively picking a suitable data structure or algorithm?