Advertisement
Guest User

isBitSet

a guest
Jan 24th, 2020
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. int cell(const int& c)
  2. {
  3. int test_bit = 1;
  4. test_bit <<= (c - c / 8);
  5. if (cells[c / 8] & test_bit)
  6. return 1;
  7. else
  8. return 0;
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement