0
$\begingroup$

Assuming we have two integers a and b, if we do bitwise operations like a & b or a | b, is the running time O(1) (constant) or is it O(b) where b is the number of bits in a and b? Thanks!

$\endgroup$
2
  • 1
    $\begingroup$ This will depend on the model of computation. $\endgroup$
    – Juho
    Oct 15 '15 at 9:47
  • $\begingroup$ Thanks for your answer. What do you mean by the model of computation? $\endgroup$
    – programmer
    Oct 15 '15 at 9:50