Skip to content

Instantly share code, notes, and snippets.

@andydude
Created June 9, 2019 16:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andydude/6c97aaf4f40d13154757aca9f14abe32 to your computer and use it in GitHub Desktop.
Save andydude/6c97aaf4f40d13154757aca9f14abe32 to your computer and use it in GitHub Desktop.
bool btr(int *a, int b) {
int c = (*a >> b) & 1;
*a &= ~(1 << b);
return c;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment