a、b转10进制,求和,再转2进制输出
def addBinary(self, a: str, b: str) -> str: return bin(int(a, 2) + int(b, 2))[2:] print(addBinary(str, '1010', '1011'))