Is there a way to convert true of type unicode to 1 and false of type unicode to 0 (in Python)?
true
unicode
false
For example: x
x
If B is a Boolean array, write
B
B = B*1
(A bit code golfy.)