def main():
    s = input()

    print(min(s.count("0"), s.count("1")) * 2)


if __name__ == "__main__":
    main() def main():
    s = input()

    print(min(s.count("0"), s.count("1")) * 2) main s = input() s input() input print(min(s.count("0"), s.count("1")) * 2) print min(s.count("0"), s.count("1")) * 2 min(s.count("0"), s.count("1")) min s.count("0") s.count s count "0" s.count("1") s.count s count "1" 2 if __name__ == "__main__":
    main() __name__ == "__main__" __name__ "__main__" main() main def main():
    s = input()

    print(min(s.count("0"), s.count("1")) * 2) def main():
    s = input()

    print(min(s.count("0"), s.count("1")) * 2) main
def main():
    s = input()

    print(min(s.count("0"), s.count("1")) * 2)


if __name__ == "__main__":
    main()
