Two's Complement in Python
18:18 21 Oct 2009

Is there a built in function in python which will convert a binary string, for example '111111111111', to the two's complement integer -1?

python bit-manipulation twos-complement