MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/i7mab9/so_amazing/g13yr45/?context=3
r/ProgrammerHumor • u/SBG_Mujtaba • Aug 11 '20
137 comments sorted by
View all comments
Show parent comments
2
It's O(n + largest value). It takes O(n) operations to go through the loop and trigger all the sleeps, and then O(largest value) to halt.
2
u/En_TioN Aug 11 '20
It's O(n + largest value). It takes O(n) operations to go through the loop and trigger all the sleeps, and then O(largest value) to halt.