s = input()
cnt_1 = s.count("1")
cnt_0 = s.count("0")

print(2 * min(cnt_1, cnt_0)) s = input() s input() input cnt_1 = s.count("1") cnt_1 s.count("1") s.count s count "1" cnt_0 = s.count("0") cnt_0 s.count("0") s.count s count "0" print(2 * min(cnt_1, cnt_0)) print 2 * min(cnt_1, cnt_0) 2 min(cnt_1, cnt_0) min cnt_1 cnt_0 s = input() input() s cnt_1 = s.count("1") s.count("1") cnt_1 cnt_0 = s.count("0") s.count("0") cnt_0
s = input()
cnt_1 = s.count("1")
cnt_0 = s.count("0")

print(2 * min(cnt_1, cnt_0))