s = input()
b = 0
w = 0
for i in range(len(s)):
    if(s[i] == '0'):
        b = b+1
    if(s[i] == '1'):
        w = w+1

print(2*min(b,w))
 s = input() s input() input b = 0 b 0 w = 0 w 0 for i in range(len(s)):
    if(s[i] == '0'):
        b = b+1
    if(s[i] == '1'):
        w = w+1 i range(len(s)) range len(s) len s if(s[i] == '0'):
        b = b+1
     s[i] == '0' s[i] s i '0' b = b+1 b b+1 b 1 if(s[i] == '1'):
        w = w+1 s[i] == '1' s[i] s i '1' w = w+1 w w+1 w 1 print(2*min(b,w)) print 2*min(b,w) 2 min(b,w) min b w w = 0 0 w w = w+1 w+1 w b = b+1 b+1 b s = input() input() s b = 0 0 b
s = input()
b = 0
w = 0
for i in range(len(s)):
    if(s[i] == '0'):
        b = b+1
    if(s[i] == '1'):
        w = w+1

print(2*min(b,w))

