4 ms·
I don't think anyone is suggesting that every programmer implements their own list every time they use a list. But it's useful to have an understanding of how c
by elric 3y ago
I don't think anyone is suggesting that every programmer implements their own list every time they use a list. But it's useful to have an understanding of how common data structures work, how basic algorithms operate, and what kind of things are out there.
Writing software is much easier when you know that things like B-Trees exist or how breadth-first search works. How do you know where to find things like this in your library if you don't even know they exist?
- LabMechanic 3y agoYep, following rules like "never ever use goto" or "use design patterns and OOP everywhere" makes no sense, if (typical) software development itself is not exact. Some folks mix up software development with being super precise and mathematical, but it's not that exact. So do repeat yourself, if the alternative is not worthwhile. As a concrete example, I don't need to download an engine (such as Unreal/Unity) to make a retro-styled 3D game. All I need are software rendering algorithms, SDL2 and maybe Rust. That's it.
- gwbas1c 3y ago> I don't think anyone is suggesting that every programmer implements their own list every time they use a list. But it's useful to have an understanding of how common data structures work, how basic algorithms operate, and what kind of things are out there. And, when you need to optimize or handle special cases on critical paths, you may end up needing to implement these algorithms yourself. Case in point: I once lead development of a major competitor to Dropbox. We couldn't use "off the shelf" queues and lists to manage upload and downloads, because there were too many special cases. I also had to implement my own immutable collections (until a library was released and we switched to it.) But otherwise, 99% of the product used off-the-shelf list and queues under the hood.