Hacker News new | ask | show | jobs
by testaccount28 46 days ago
for any fixed size, populating the lookup table is constant.
1 comments

If it's 2^n size, you don't get to assume that filling it is O(1) or even O(n) in really any model unless it says that. That would be quite surprising when analysing this type of problem, because it makes anything about the problem _very_ boring, all the answers are just O(1) then, there's nothing to think or care about then.

2^n isn't a "fixed size" here.