Leetcode/python/67_add_binary.py
2024-04-08 16:38:50 +01:00

4 lines
110 B
Python

class Solution:
def addBinary(self, a: str, b: str) -> str:
return bin(int(a, 2) + int(b, 2))[2:]