In C I could, for example, zero out bit #10 in a 32 bit unsigned value like so:
unsigned long value = 0xdeadbeef; value &= ~(1<<10);
Omit the 'unsigned long', and the semi-colons are not needed either:
value = 0xDEADBEEF value &= ~(1<<10) print value "0x%08X" % value