Hacker News new | past | comments | ask | show | jobs | submit login

Is there a way to keep a list with changing values sorted in real time in order to use a log n search algorithm?



Yes, a binary search tree that is dynamically balanced, for example red-black or avl.


It's log n either way.




Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: