S=input()
a=S.count("1")
b=S.count("0")
print(min(a,b)*2)
157162e6521b409281a347b8cbcca28a59204d3c
<mask token>

<mask token>
print(min(a, b) * 2)

S = input()
a = S.count('1')
b = S.count('0')
print(min(a, b) * 2)

S=input()
a=S.count("1")
b=S.count("0")
print(min(a,b)*2)