3 ms·
No, I don't think so. O(1) is "constant" time. See https://en.wikipedia.org/wiki/Time_complexity https://en.wikipedia.org/wiki/Time_complexity
by tantalor 11y ago
No, I don't think so. O(1) is "constant" time. See https://en.wikipedia.org/wiki/Time_complexity https://en.wikipedia.org/wiki/Time_complexity
- Dylan16807 11y agoO(1) is a constant time bound. But when people talk about constant time they often mean literally constant, such as to avoid timing attacks.
- dragonwriter 11y agoIts true that constant time is sometimes used in that way, though in discussions of computation complexity, "constant time" usually means O(1). There narrower use is more like Θ(1) with the upper and lower constants identical.