Flip Bit Python spécifique

# To flip the kth bit of x, XOR it with 1 leftshifted k times 
x = x ^ (1 << k)
Sore Stag