That particular lookup table would be O(n), and it wouldn't support unbounded inputs.