What RomanHume said.
I still miss that turtle.
There are very rare times when code isn't reused.
1. Cutting Edge: This is the hot new shit no one knows how to do and so it has to be invented, so AI, Quantum Computing, Computer Brain interfaces, etc.
2. Extremely old or side shit no one wrote down: Making an emulator for a video game system and you need to code for an exercise bike peripheral.
You must be registered to see the links
3. Stubborn people AKA wheel reinventors: A lot of time this falls under self learning or not wanting to use others work, but it can also be something similar to avoiding leaks. A modern take would be the Nintendo code leaks where Emulator developers could get into legal trouble if they used said leaked code, so they fully avoid it instead.
4. Rewriters: These are the people who mainly convert code to other languages, So esoteric shit in Fortran to Python, this can also be people who don't want to plagiarizer or want to enhance it, they get the old code to understand then write it more concisely