Re:Sleeping Through the Technical Interview (2022)
by jnwatson on Friday July 07, 2023 @03:26PM
(#36637073)
It isn’t really linear. Sleeping is a heap insertion which takes O(log n).
[ Parent
| on HN ]
Re:Sleeping Through the Technical Interview (2022)
by bmacho on Friday July 07, 2023 @03:49PM
(#36637400)
You still have to read all the inputs at least, which is at least linear time, in the size of the input.
Re:Sleeping Through the Technical Interview (2022)
by QuadmasterXLII on Friday July 07, 2023 @03:58PM
(#36637500)
Each sleep is log n for the heap insertion, so the overall complexity is at least n log n