I was just watching a video about algorithm performance by the @ThePrimeagen . It reminded that Big-O complexity is not always the final story. When choosing a data structure, it's useful to consider the 'composition hierarchy'. You can implement an algorithm using a Hash…
Here's the video btw: youtube.com/watch?v=U16Rnp… Genuinely one of the best videos I've ever watched
i agree, that's why arrays are better than hashsets in many cases, for some ppl this is counter intuitive
"prob because you use a fake language like JS or Python"😂😂😂
The correct term for this consideration is called "cache coherency". This is why linked-list are virtually never faster than the corresponding array of pointers even after memory allocation optimizations.
Also, With small amounts of data the chances of key collision is high And in some implementations, key collisions are handled by using a linked list - which might result into 0(n) lookup in the worst case
I agree. Moreover, if someone is deciding what approach to use for a specific application solely by big O ordering, they probably don't understand what big O is.
Wow, gonna watch the video now. Each iteration is leading to crazy optimization here.
I wonder if all interpreted languages are fake, or what other properties would make it fake
This is what cs degree taught people to think and use all the tools available and mix match with problem set .
is neetcode.io broken? all my progress is lost navi and its not opening up the problems...
United States 趨勢
- 1. Good Sunday 55.3K posts
- 2. Bears 142K posts
- 3. Bears 142K posts
- 4. Happy Winter Solstice 5,398 posts
- 5. And Mary 27.7K posts
- 6. #sundayvibes 3,293 posts
- 7. Caleb Williams 39.7K posts
- 8. Snowball 11.2K posts
- 9. Malik Willis 15.6K posts
- 10. DJ Moore 29.5K posts
- 11. Ben Johnson 10.4K posts
- 12. Doubs 9,166 posts
- 13. #BearDown 4,748 posts
- 14. Nixon 12.9K posts
- 15. #BlackClover 9,171 posts
- 16. Jordan Love 13.3K posts
- 17. #Toonami 2,513 posts
- 18. TOP CALL 7,300 posts
- 19. Bowen 14.3K posts
- 20. Andrew Tate 72.6K posts
Something went wrong.
Something went wrong.