Buggy python submission (verdict: Runtime Error):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
pirnt(ans*2)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)

Buggy python submission (verdict: Time Limit Exceeded):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]
offset = 0
count = 0
while len(ls) >= 2:
    if ls[offset] != ls[offset +1]:
        del ls[offset:offset +2]
        count += 2
        offset = 0
    elif offset + 2 == len(ls):
        break
    else:
        offset += 1

print(count)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)

Buggy python submission (verdict: Time Limit Exceeded):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]
offset = 0
count = 0
while len(ls) >= 2:
    if ls[offset] != ls[offset +1]:
        del ls[offset:offset +2]
        count += 2
        offset = 0
    elif offset + 2 == len(ls):
        break
    else:
        offset += 1

print(count)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)

Buggy python submission (verdict: Runtime Error):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]
offset = 0
count = 0
while len(ls) >= 2:
    if ls[offset] != ls[offset +1]:
        del ls[offset:offset +2]
        count += 2
        offset = 0
    elif offset + 1 == len(ls):
        break
    else:
        offset += 1

print(count)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)

Buggy python submission (verdict: Runtime Error):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]
offset = 0
count = 0
while True:
    if ls[offset] == ls[offset +1]:
        del ls[offset:offset +2]
        count += 2
        offset = 0
    elif offset + 1 == len(ls):
        break
    else:
        offset += 1

print(count)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)

Buggy python submission (verdict: Runtime Error):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]
offset = 0
count = 0
while True:
    if ls[offset] == ls[offset +1]:
        del ls[offset:offset +2]
        count += 2
    elif offset +1 ==len(ls):
        break
    else:
        offset += 1

print(count)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)

Buggy python submission (verdict: Runtime Error):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]
offset = 0
count = 0
while True:
    if ls[offset] == ls[offset +1]:
        del ls[offset:offset +2]
        count += 2
    elif offset +1 ==len(ls):
        break

    else:
        offset += 1

print(count)

Fixed submission:
#! /usr/bin/env python3
# -*- coding: utf-8 -*-

S = input()
ls = list(S)
ls = [int(x) for x in ls]

ans = min(ls.count(0),ls.count(1))
print(ans*2)