S = input()

zero = S.count("0")
one = S.count("1")

if zero != 0 and one != 0:
  print(min(zero,one)*2)
else:
  print(0) S = input() S input() input zero = S.count("0") zero S.count("0") S.count S count "0" one = S.count("1") one S.count("1") S.count S count "1" if zero != 0 and one != 0:
  print(min(zero,one)*2)
else:
  print(0) zero != 0 and one != 0 zero != 0 zero 0 one != 0 one 0 print(min(zero,one)*2) print min(zero,one)*2 min(zero,one) min zero one 2 print(0) print 0 zero = S.count("0") S.count("0") zero S = input() input() S one = S.count("1") S.count("1") one
S = input()

zero = S.count("0")
one = S.count("1")

if zero != 0 and one != 0:
  print(min(zero,one)*2)
else:
  print(0)