S = input()
cnt = 0
_cnt = 0
for s in S:
    if s == '0':
        cnt += 1
    else:
        _cnt += 1
print(min(cnt, _cnt) * 2) S = input() S input() input cnt = 0 cnt 0 _cnt = 0 _cnt 0 for s in S:
    if s == '0':
        cnt += 1
    else:
        _cnt += 1 s S if s == '0':
        cnt += 1
    else:
        _cnt += 1 s == '0' s '0' cnt += 1 cnt 1 _cnt += 1 _cnt 1 print(min(cnt, _cnt) * 2) print min(cnt, _cnt) * 2 min(cnt, _cnt) min cnt _cnt 2 S = input() input() S cnt = 0 0 cnt _cnt = 0 0 _cnt _cnt += 1 1 _cnt cnt += 1 1 cnt
S = input()
cnt = 0
_cnt = 0
for s in S:
    if s == '0':
        cnt += 1
    else:
        _cnt += 1
print(min(cnt, _cnt) * 2)
