Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Or, phrased differently, if n has an upper limit, the algorithm is O(1).



As long as you have tests that regularly exercise your algorithm at n=max where you would notice if they were exceptionally slow




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

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

Search: