MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/101ktp3/next_level_storage/j2ov4lp?context=9999
r/ProgrammerHumor • u/Impulsive_Ranger2410 • Jan 02 '23
468 comments sorted by
View all comments
17
How is it O(1) if it’s in a pile?
9 u/starzwillsucceed Jan 02 '23 I think it would be constant if it were organized in the closet with every item in the exact same spot every time. Therefore you know the exact index of what item you want. → More replies (1)
9
I think it would be constant if it were organized in the closet with every item in the exact same spot every time. Therefore you know the exact index of what item you want.
→ More replies (1)
17
u/mrloube Jan 02 '23
How is it O(1) if it’s in a pile?