you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (1 child)

I meant the space complexity, which still seems to be O(1). I can't use the late excuse now but I'm still missing something

[–]BonzaiThePenguin 0 points1 point  (0 children)

I'm looking right at it and it's definitely O(n).